1
0
mirror of https://github.com/labstack/echo.git synced 2025-04-17 12:06:44 +02:00
Signed-off-by: Vishal Rana <vr@labstack.com>
This commit is contained in:
Vishal Rana 2017-06-24 09:50:07 -07:00
parent 06189d002b
commit 83eadbad18

View File

@ -84,7 +84,7 @@ func StaticWithConfig(config StaticConfig) echo.MiddlewareFunc {
fi, err := os.Stat(name)
if err != nil {
if os.IsNotExist(err) {
if config.HTML5 && path.Ext(p) == "" {
if config.HTML5 && path.Ext(p) != "" {
return c.File(filepath.Join(config.Root, config.Index))
}
return next(c)