moves and slightly refactors routes