Adjusted code to remove an unneeded logging message