From 83ff4c8ee6d3b80a3798f2406f4308bed0a8dcf0 Mon Sep 17 00:00:00 2001 From: Livio Amstutz Date: Tue, 23 Jun 2020 09:45:08 +0200 Subject: [PATCH] fix: password reset (#258) * feat: translate error messages in error interceptor * fix: add statik import * feat: user error msgs * feat: add translations * feat: add translations * feat: add translations * feat: add translations * feat: add translations * feat: add translations * some fixes and improved error messages * display loginname only on authReq * fix: login names (and query) (#253) * fix: add interceptors for console (#255) * add interceptors for console * add interceptors for console to env.json * fix: query side (#257) * fix: project by id return projectview * fix: return always view model on query side * fix: return always view model on query side Co-authored-by: Fabiennne Co-authored-by: Fabi <38692350+fgerschwiler@users.noreply.github.com> --- internal/login/handler/init_password_handler.go | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/internal/login/handler/init_password_handler.go b/internal/login/handler/init_password_handler.go index 8ef4277258..5aa1183770 100644 --- a/internal/login/handler/init_password_handler.go +++ b/internal/login/handler/init_password_handler.go @@ -93,9 +93,13 @@ func (l *Login) renderInitPassword(w http.ResponseWriter, r *http.Request, authR } func (l *Login) renderInitPasswordDone(w http.ResponseWriter, r *http.Request, authReq *model.AuthRequest) { + loginName := "" + if authReq != nil { + loginName = authReq.LoginName + } data := userData{ baseData: l.getBaseData(r, authReq, "Password Init Done", "", ""), - LoginName: authReq.LoginName, + LoginName: loginName, } l.renderer.RenderTemplate(w, r, l.renderer.Templates[tmplInitPasswordDone], data, nil) }