Refactored from directories and things