Przeglądaj źródła

Fixed bug in user creation and admin role

Torkel Ödegaard 11 lat temu
rodzic
commit
0f63c04beb
1 zmienionych plików z 1 dodań i 1 usunięć
  1. 1 1
      pkg/services/sqlstore/user.go

+ 1 - 1
pkg/services/sqlstore/user.go

@@ -91,7 +91,7 @@ func CreateUser(cmd *m.CreateUserCommand) error {
 			Updated:   time.Now(),
 		}
 
-		if setting.SingleAccountMode {
+		if setting.SingleAccountMode && !user.IsAdmin {
 			accountUser.Role = m.RoleType(setting.DefaultAccountRole)
 		}