refactored directory tree