doing refactoring