-
Notifications
You must be signed in to change notification settings - Fork 1.9k
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
Router.NotFoundHandler is not used when the router is a subrouter #20
Comments
I looked at this today but there doesn't seem to be any obvious way to implement it. NotFoundHandler is only called from ServeHTTP, which is only ever called on the top-level router and not the subrouters. Furthermore there is no concept of a partial match, that is the top-level part of the subrouter path matching but the inner part not matching. |
I've worked around this by using a
Later, |
I'm going to close this as wontfix: if you do need separate a |
I defined specific NotFoundHandler for several subrouters but the NotFoundHandler from the main Router is always used.
The text was updated successfully, but these errors were encountered: