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

middleware.CleanPath doesn't work with other routers #787

Open
romain-tadiello opened this issue Jan 27, 2023 · 0 comments
Open

middleware.CleanPath doesn't work with other routers #787

romain-tadiello opened this issue Jan 27, 2023 · 0 comments

Comments

@romain-tadiello
Copy link

The rctx is not checked and could be nil if the function isn't used with a chi.Router.
It ends up in a panic.

PR: #786

Additional point: the cleaning only happens in the rctx.RoutePath is an empty string. If a function like GetHead is called before it won't clean the path.

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

No branches or pull requests

1 participant