Removed unused code and comments