correctFolder() already resolves the dirname internally