refactoring create path