finished refactoring routes