-
Notifications
You must be signed in to change notification settings - Fork 15
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
[fix #3] overlapping routes may not be matched
When a router includes two routes that overlap, such as `GET /foo/:id` and `POST /foo/bar`, requests for the second route may sometimes fail with a `405 Method Not Allowed` response. This happens because the router will sometimes match the first route instead of the second one, due to the non-deterministic nature of the route map. This commit fixes the issue by continuing the matching process if the request method is not supported by the first matched route.
- Loading branch information
Showing
2 changed files
with
45 additions
and
5 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters