Fixed Change Password Bug
This commit is contained in:
parent
401bd0dac1
commit
73f0b98adc
1 changed files with 10 additions and 11 deletions
7
home.go
7
home.go
|
@ -15,13 +15,12 @@ type HomePageData struct {
|
||||||
}
|
}
|
||||||
|
|
||||||
func handleHome(w http.ResponseWriter, r *http.Request) {
|
func handleHome(w http.ResponseWriter, r *http.Request) {
|
||||||
templateHome := getTemplate("home.html")
|
|
||||||
|
|
||||||
login := checkLogin(w, r)
|
login := checkLogin(w, r)
|
||||||
if login == nil {
|
if login == nil {
|
||||||
return
|
return
|
||||||
}
|
} else {
|
||||||
|
templateHome := getTemplate("home.html")
|
||||||
data := &HomePageData{
|
data := &HomePageData{
|
||||||
Login: login,
|
Login: login,
|
||||||
BaseDN: config.BaseDN,
|
BaseDN: config.BaseDN,
|
||||||
|
@ -29,6 +28,6 @@ func handleHome(w http.ResponseWriter, r *http.Request) {
|
||||||
CanAdmin: login.CanAdmin,
|
CanAdmin: login.CanAdmin,
|
||||||
LoggedIn: true,
|
LoggedIn: true,
|
||||||
}
|
}
|
||||||
|
|
||||||
templateHome.Execute(w, data)
|
templateHome.Execute(w, data)
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue