We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
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
with a route like this
r := chi.NewRouter() r.Get("/", handler)
when a request to localhost:8080/ is received, the method chi.RouteContext(r.Context()).RoutePattern() return ""
localhost:8080/
chi.RouteContext(r.Context()).RoutePattern()
""
I think the expected value is /
/
maybe this can help
func (x *Context) RoutePattern() string { routePattern := strings.Join(x.RoutePatterns, "") routePattern = replaceWildcards(routePattern) routePattern = strings.TrimSuffix(routePattern, "//") if len(routePattern) > 1 { routePattern = strings.TrimSuffix(routePattern, "/") } return routePattern }
The text was updated successfully, but these errors were encountered:
fix for issue go-chi#846
ab7fc4d
fix: #846 (#847)
f4ab9b1
Successfully merging a pull request may close this issue.
with a route like this
when a request to
localhost:8080/
is received, the methodchi.RouteContext(r.Context()).RoutePattern()
return""
I think the expected value is
/
maybe this can help
The text was updated successfully, but these errors were encountered: