Skip to content

Commit

Permalink
Merge commit '086824521bd13c71f3999ca6adca1a39a35eab45' into dev-k8s-…
Browse files Browse the repository at this point in the history
…yongsik
  • Loading branch information
yongsikgi committed Dec 1, 2021
2 parents 6f65394 + 0868245 commit c1a45d9
Showing 1 changed file with 8 additions and 1 deletion.
9 changes: 8 additions & 1 deletion backend/server/users.go
Original file line number Diff line number Diff line change
Expand Up @@ -688,7 +688,14 @@ func (s *Service) OrganizationUpdateUser(w http.ResponseWriter, r *http.Request)
return
}

u.Roles = roles
// change req.Roles in u.Roles
for i, existRule := range u.Roles {
for _, role := range roles {
if existRule.Organization == role.Organization {
u.Roles[i] = role
}
}
}

// If the request contains a name, it must be the same as the
// one on the user. This is particularly useful to the front-end
Expand Down

0 comments on commit c1a45d9

Please sign in to comment.