From 6ff0805b1b99206d7136afecea285ca7ada1dc8e Mon Sep 17 00:00:00 2001 From: mappu Date: Sat, 8 Oct 2016 15:19:58 +1300 Subject: [PATCH] default route support --- main.go | 3 +++ 1 file changed, 3 insertions(+) diff --git a/main.go b/main.go index 7019186..880d359 100644 --- a/main.go +++ b/main.go @@ -183,6 +183,9 @@ func (this *App) ConfigRequestHandler(w http.ResponseWriter, r *http.Request) { func (this *App) StaticRequestHandler(w http.ResponseWriter, r *http.Request) { fileName := r.URL.Path[1:] + if fileName == "" { + fileName = "index.htm" + } data, err := Asset(fileName) if err != nil {