Fixed the issues mentioned in the code review.

Removed the debug/console output.