Added logic to handle new stock entries