cleaned up obsolete and deprecated code