mirror of
https://github.com/minio/minio.git
synced 2024-12-24 22:25:54 -05:00
fix: allow admins to create users (#11005)
PR #10978 introduced a regression, root credential should be allowed to create users
This commit is contained in:
parent
2f564437ae
commit
7cbca43eb1
@ -379,7 +379,7 @@ func (a adminAPIHandlers) AddUser(w http.ResponseWriter, r *http.Request) {
|
||||
}
|
||||
|
||||
// Not allowed to add a user with same access key as root credential
|
||||
if owner {
|
||||
if owner && accessKey == cred.AccessKey {
|
||||
writeErrorResponseJSON(ctx, w, errorCodes.ToAPIErr(ErrAddUserInvalidArgument), r.URL)
|
||||
return
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user