refactored everything to comply with the style guide