some cleanup and method renaming