mirror of
https://github.com/kataras/iris.git
synced 2025-02-02 23:40:35 +01:00
Former-commit-id: 13d1a274518ed6b2fdfa9fefd02021b0ebc3071f
This commit is contained in:
parent
cf1e580cde
commit
3e6ec4d441
|
@ -661,7 +661,12 @@ func (api *APIBuilder) StaticEmbedded(requestPath string, vdir string, assetFn f
|
||||||
fullpath := joinPath(api.relativePath, requestPath)
|
fullpath := joinPath(api.relativePath, requestPath)
|
||||||
requestPath = joinPath(fullpath, WildcardParam("file"))
|
requestPath = joinPath(fullpath, WildcardParam("file"))
|
||||||
|
|
||||||
h := StripPrefix(fullpath, api.StaticEmbeddedHandler(vdir, assetFn, namesFn))
|
h := api.StaticEmbeddedHandler(vdir, assetFn, namesFn)
|
||||||
|
|
||||||
|
if fullpath != "/" {
|
||||||
|
h = StripPrefix(fullpath, h)
|
||||||
|
}
|
||||||
|
|
||||||
return api.registerResourceRoute(requestPath, h)
|
return api.registerResourceRoute(requestPath, h)
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue
Block a user