diff options
Diffstat (limited to 'routers/admin/users.go')
-rw-r--r-- | routers/admin/users.go | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/routers/admin/users.go b/routers/admin/users.go index 8a848b1f9d..9fe5c3ef7d 100644 --- a/routers/admin/users.go +++ b/routers/admin/users.go @@ -267,7 +267,10 @@ func EditUserPost(ctx *context.Context, form auth.AdminEditUserForm) { ctx.ServerError("UpdateUser", err) return } - u.HashPassword(form.Password) + if err = u.SetPassword(form.Password); err != nil { + ctx.InternalServerError(err) + return + } } if len(form.UserName) != 0 && u.Name != form.UserName { |