-
Notifications
You must be signed in to change notification settings - Fork 74
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
Return MethodNotAllowed for request with wrong HTTP method #111
Comments
Nice idea.
|
@untitaker Can't we just check for each method? |
True, but that's slightly slower in the case of a 405. |
I have solution of this case.
|
Cool, please make a PR :) |
Hi guys, i have couple questions.
|
Yes exactly. I don't think we need a flag. |
Add PR #131 |
Closed by #131 |
I had to revert #131 because it introduced a bug. Resolving by path first was a mistake. I added a testcase in master and published 0.5.1 |
It would be great if router would return a "HTTP 405 Method Not Allowed" for routes where a route exists, but a non-matching request method was used.
Example:
Here a PUT request to /things should result in a HTTP 405.
I realize that this could be implemented with an
any
route for all paths, but turning this on globally would make things much simpler.The text was updated successfully, but these errors were encountered: