refactoring things