Do not use `ctx.Doer` when reset password (#29289)

Fix #29278.

Caused by a small typo in #28733
pull/29287/head^2
Jason Song 12 months ago committed by GitHub
parent 3d3c3d9ee5
commit 22b8de85dd
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
  1. 2
      routers/web/auth/password.go

@ -204,7 +204,7 @@ func ResetPasswdPost(ctx *context.Context) {
Password: optional.Some(ctx.FormString("password")),
MustChangePassword: optional.Some(false),
}
if err := user_service.UpdateAuth(ctx, ctx.Doer, opts); err != nil {
if err := user_service.UpdateAuth(ctx, u, opts); err != nil {
ctx.Data["IsResetForm"] = true
ctx.Data["Err_Password"] = true
switch {

Loading…
Cancel
Save