Removed obsolete code and comments