refactoring methods to be more succinct