diff --git a/handler.go b/handler.go index d4393e1..9cbf464 100644 --- a/handler.go +++ b/handler.go @@ -53,6 +53,11 @@ func (h *handler) ServeHTTP(w http.ResponseWriter, r *http.Request) { r.Method = r.Form.Get("_method") } + if r.URL.Path == h.prefix { + http.Redirect(w, r, path.Join(h.prefix, "/login/"), http.StatusFound) + return + } + if r.URL.Path == path.Join(h.prefix, "/login/") && r.Method == http.MethodGet { h.login(w, r)