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

Fix regular expression for optional params #32

Merged
merged 1 commit into from
Apr 9, 2024
Merged

Conversation

easing
Copy link
Contributor

@easing easing commented Apr 9, 2024

The router converts patterns with optional parameters to regular expressions that are not strict enough.

Example: /profile/:id?/:tab? matches /profile-random-bug, /profile// and /profile/// paths.

This PR fixes it.

11 bytes added.

@ai ai merged commit 9fd597e into nanostores:main Apr 9, 2024
3 checks passed
@ai
Copy link
Member

ai commented Apr 9, 2024

Thanks a lot!

@ai
Copy link
Member

ai commented Apr 9, 2024

Released in 0.14.2

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.

2 participants