cleaned up the deprecated code and comments