summaryrefslogtreecommitdiffstats
path: root/vendor/github.com/labstack/echo/v4/router.go
diff options
context:
space:
mode:
Diffstat (limited to 'vendor/github.com/labstack/echo/v4/router.go')
-rw-r--r--vendor/github.com/labstack/echo/v4/router.go4
1 files changed, 4 insertions, 0 deletions
diff --git a/vendor/github.com/labstack/echo/v4/router.go b/vendor/github.com/labstack/echo/v4/router.go
index 15a3398f..ed728d6a 100644
--- a/vendor/github.com/labstack/echo/v4/router.go
+++ b/vendor/github.com/labstack/echo/v4/router.go
@@ -355,6 +355,10 @@ func (r *Router) Find(method, path string, c Context) {
// Attempt to go back up the tree on no matching prefix or no remaining search
if l != pl || search == "" {
+ // Handle special case of trailing slash route with existing any route (see #1526)
+ if path[len(path)-1] == '/' && cn.findChildByKind(akind) != nil {
+ goto Any
+ }
if nn == nil { // Issue #1348
return // Not found
}