From fd4efc08bf78824ea9e14080721141b7e5e1f422 Mon Sep 17 00:00:00 2001 From: Chris Mann Date: Wed, 26 Jul 2023 09:02:42 +0200 Subject: [PATCH] Refactoring --- view-passwd.go | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/view-passwd.go b/view-passwd.go index d1140d3..e79d724 100644 --- a/view-passwd.go +++ b/view-passwd.go @@ -77,7 +77,9 @@ func handlePasswd(w http.ResponseWriter, r *http.Request) { login := checkLogin(w, r) if login == nil { data.Common.LoggedIn = false - templatePasswd.Execute(w, data) + http.Redirect(w, r, "/", http.StatusFound) + + // templatePasswd.Execute(w, data) return } data.Login.Status = login