Merge pull request #998 from influxdata/hotfix/fix-user-rolevalidation
Update user's roles validationpull/993/head^2
commit
07192d89d8
|
@ -245,7 +245,7 @@ type usersResponse struct {
|
|||
}
|
||||
|
||||
func (r *userRequest) ValidUpdate() error {
|
||||
if r.Password == "" && len(r.Permissions) == 0 {
|
||||
if r.Password == "" && len(r.Permissions) == 0 && len(r.Roles) == 0 {
|
||||
return fmt.Errorf("No fields to update")
|
||||
}
|
||||
return validPermissions(&r.Permissions)
|
||||
|
|
Loading…
Reference in New Issue