mirror of
https://github.com/labstack/echo.git
synced 2025-07-17 01:43:02 +02:00
param wildcard capture fixed to *
Signed-off-by: Vishal Rana <vr@labstack.com>
This commit is contained in:
@ -70,7 +70,7 @@ func StaticWithConfig(config StaticConfig) echo.MiddlewareFunc {
|
||||
fs := http.Dir(config.Root)
|
||||
p := c.Request().URL.Path
|
||||
if strings.Contains(c.Path(), "*") { // If serving from a group, e.g. `/static*`.
|
||||
p = c.Param("_*")
|
||||
p = c.Param("*")
|
||||
}
|
||||
file := path.Clean(p)
|
||||
f, err := fs.Open(file)
|
||||
|
Reference in New Issue
Block a user