refactoring dir