factored out recognize_route
remove unnecessary next
recognize_route -> recognize_path
move normalizing into recognize_path