1
0
mirror of https://github.com/labstack/echo.git synced 2025-01-24 03:16:14 +02:00

Revert "Remove group.Use registering Any routes that break other routes"

This reverts commit f72eaa42
This commit is contained in:
toimtoimtoim 2020-12-17 02:01:59 +02:00
parent 628a2df08c
commit 655596b1b9

View File

@ -23,6 +23,10 @@ func (g *Group) Use(middleware ...MiddlewareFunc) {
if len(g.middleware) == 0 {
return
}
// Allow all requests to reach the group as they might get dropped if router
// doesn't find a match, making none of the group middleware process.
g.Any("", NotFoundHandler)
g.Any("/*", NotFoundHandler)
}
// CONNECT implements `Echo#CONNECT()` for sub-routes within the Group.