Refactoring on the Routes view