-
Notifications
You must be signed in to change notification settings - Fork 67
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Documentation on how routes are prioritized #45
Comments
OK, I see the problem. I think that the |
Agreed, |
Could you not just change the order of the routes? |
To add to @cullophid I agree it's nice about this explicit ordering plus the |
Will be fixed by #215 . We're not going to allow the default router to have ambiguous routing. |
Given a modified version of the README example:
With this code I see "Hello test" if I
GET /hello/test
and "Hello everyone else" if I use other paths. However, if I swap the lines between the comments above then the only response "Hello everyone else". OCaml 4.02.3 + opium 0.13.3 + cohttp 0.19.3 from opam.I'm not sure what the right approach is here. It's useful to be able to have specific routes with an catch-all to handle all other requests. It would be useful if the right way to do this were shown in the README or somewhere similarly visible.
The text was updated successfully, but these errors were encountered: