flounder

A simple gemini site builder
Log | Files | Refs | README | LICENSE

commit 055fcbe201d0fd4c1dd9b1c966359cdc9a11b31f
parent 3b51a8b227148b98f16b949cbc3265df1b889936
Author: alex wennerberg <alex@alexwennerberg.com>
Date:   Sun,  6 Dec 2020 11:21:32 -0800

cleanup errors

Diffstat:
Mhttp.go | 5+++--
1 file changed, 3 insertions(+), 2 deletions(-)

diff --git a/http.go b/http.go @@ -283,7 +283,8 @@ func myAccountHandler(w http.ResponseWriter, r *http.Request) { // Rename User err = renameUser(authUser, newUsername) if err != nil { - errors = append(errors, err.Error()) + log.Println(err) + errors = append(errors, "Could not rename user") } else { session, _ := SessionStore.Get(r, "cookie-session") session.Values["auth_user"] = newUsername @@ -596,7 +597,7 @@ func resetPasswordHandler(w http.ResponseWriter, r *http.Request) { } else { err = bcrypt.CompareHashAndPassword(currPass, []byte(enteredCurrPass)) if err == nil { - hashedPassword, err := bcrypt.GenerateFromPassword([]byte(password1), 8) // TODO handle error + hashedPassword, err := bcrypt.GenerateFromPassword([]byte(password1), 8) if err != nil { panic(err) }