#2937 able to prohibit user login
This commit is contained in:
parent
52322ef624
commit
c083d76567
11 changed files with 41 additions and 6 deletions
|
@ -206,6 +206,7 @@ func EditUserPost(ctx *context.Context, form auth.AdminEditUserForm) {
|
|||
u.IsAdmin = form.Admin
|
||||
u.AllowGitHook = form.AllowGitHook
|
||||
u.AllowImportLocal = form.AllowImportLocal
|
||||
u.ProhibitLogin = form.ProhibitLogin
|
||||
|
||||
if err := models.UpdateUser(u); err != nil {
|
||||
if models.IsErrEmailAlreadyUsed(err) {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue