Skip to content
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

Allow for a leaf to order regexps such that ones with patterns are ch… #74

Open
wants to merge 3 commits into
base: master
Choose a base branch
from

Conversation

AlskiOnTheWeb
Copy link

@AlskiOnTheWeb AlskiOnTheWeb commented Nov 23, 2016

This pull request will fix the case where a node in the route tree has several entries. Ones with regexps are weighted to be checked first. The case it fixes are when there are routes like:

/a/:b

and

/a/:b:.*\.json

The current behavior is that the second case will never be checked because the first always matches. This pull will ensure that the "with json extension" will be checked first.

@AlskiOnTheWeb
Copy link
Author

I've added one more feature that we use. In the case that a path parameter uses a pattern that has a capturing group, that captured group will be returned as the path value when appropriate.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant