mirror of
https://github.com/go-gitea/gitea
synced 2025-07-22 18:28:37 +00:00
Make possible for administrators to change user's password (fix proposal for #290)
This commit is contained in:
@@ -134,6 +134,13 @@ func EditUserPost(ctx *middleware.Context, params martini.Params, form auth.Admi
|
||||
return
|
||||
}
|
||||
|
||||
if (form.Passwd != "") {
|
||||
u.Passwd = form.Passwd
|
||||
u.Rands = models.GetUserSalt()
|
||||
u.Salt = models.GetUserSalt()
|
||||
u.EncodePasswd()
|
||||
}
|
||||
|
||||
u.Email = form.Email
|
||||
u.Website = form.Website
|
||||
u.Location = form.Location
|
||||
|
Reference in New Issue
Block a user