1
0
mirror of https://github.com/labstack/echo.git synced 2024-12-22 20:06:21 +02:00

Merge pull request #338 from o1egl/fix_windows_static

Fix serving static files on windows.
This commit is contained in:
Vishal Rana 2016-01-29 00:03:44 -08:00
commit 055e7ae0e6

View File

@ -7,6 +7,7 @@ import (
"fmt"
"io"
"net/http"
"path"
"path/filepath"
"reflect"
"runtime"
@ -429,7 +430,7 @@ func (e *Echo) serveFile(dir, file string, c *Context) (err error) {
d := f
// Index file
file = filepath.Join(file, indexPage)
file = path.Join(file, indexPage)
f, err = fs.Open(file)
if err != nil {
if e.autoIndex {