Fixed bugs on routes