return errors instead of panicing

This commit is contained in:
Aaron Bieber 2020-04-30 06:16:50 -06:00
parent f301e8c35a
commit 480481afee

View File

@ -29,7 +29,8 @@ func Auth(w http.ResponseWriter, r *http.Request) {
user, err := base.AuthUser(ctx, p)
if err != nil {
panic(err)
http.Error(w, err.Error(), http.StatusInternalServerError)
return
}
if user.Authed {