Compare commits
3 commits
9333574de2
...
1cd15d51e4
| Author | SHA1 | Date | |
|---|---|---|---|
| 1cd15d51e4 | |||
| eb7b1cf026 | |||
| 0065861eab |
1 changed files with 1 additions and 1 deletions
2
main.go
2
main.go
|
|
@ -174,7 +174,7 @@ func main() {
|
|||
|
||||
// serve index.html if present (case-sensitive)
|
||||
indexPath := filepath.Join(fpath, "index.html")
|
||||
if _, err := os.Stat(indexPath); err == nil {
|
||||
if indexInfo, err := os.Stat(indexPath); err == nil && !indexInfo.IsDir() {
|
||||
http.ServeFile(w, r, indexPath)
|
||||
return
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue