fixed a redirect loop caused by route order