Fixed NPE after deleting stock