1
0
mirror of https://github.com/labstack/echo.git synced 2025-07-15 01:34:53 +02:00

param wildcard capture fixed to *

Signed-off-by: Vishal Rana <vr@labstack.com>
This commit is contained in:
Vishal Rana
2016-10-10 18:36:48 -07:00
parent 8623669cbc
commit 2eb87f8036
4 changed files with 6 additions and 6 deletions

View File

@ -81,7 +81,7 @@ func (r *Router) Add(method, path string, h HandlerFunc, e *Echo) {
r.insert(method, path[:i], nil, pkind, ppath, pnames, e)
} else if path[i] == '*' {
r.insert(method, path[:i], nil, skind, "", nil, e)
pnames = append(pnames, "_*")
pnames = append(pnames, "*")
r.insert(method, path[:i+1], h, akind, ppath, pnames, e)
return
}