Fixed Change Password Bug

This commit is contained in:
Chris Mann 2023-07-25 14:34:19 +02:00
parent 73f0b98adc
commit f65319fd93
2 changed files with 12 additions and 17 deletions

View file

@ -18,8 +18,10 @@ func handleHome(w http.ResponseWriter, r *http.Request) {
login := checkLogin(w, r) login := checkLogin(w, r)
if login == nil { if login == nil {
handleLogin(w, r)
return return
} else { }
templateHome := getTemplate("home.html") templateHome := getTemplate("home.html")
data := &HomePageData{ data := &HomePageData{
Login: login, Login: login,
@ -29,5 +31,5 @@ func handleHome(w http.ResponseWriter, r *http.Request) {
LoggedIn: true, LoggedIn: true,
} }
templateHome.Execute(w, data) templateHome.Execute(w, data)
}
} }

View file

@ -25,13 +25,6 @@ func checkLogin(w http.ResponseWriter, r *http.Request) *LoginStatus {
} }
} }
if login_info == nil {
login_info = handleLogin(w, r)
if login_info == nil {
return nil
}
}
l, err := ldapOpen(w) l, err := ldapOpen(w)
if l == nil { if l == nil {
return nil return nil