KEYCLOAK-8783 also checked admin roles when realm admin client is specified

This commit is contained in:
Gideon Caranzo 2018-11-13 14:36:18 +08:00 committed by Marek Posolda
parent 9f88abb022
commit 39bf08e1b9

View file

@ -531,7 +531,7 @@ public class RealmManager {
setupMasterAdminManagement(realm); setupMasterAdminManagement(realm);
} }
if (rep.getRoles() != null) { if (rep.getRoles() != null || hasRealmAdminManagementClient(rep)) {
// Assert all admin roles are available once import took place. This is needed due to import from previous version where JSON file may not contain all admin roles // Assert all admin roles are available once import took place. This is needed due to import from previous version where JSON file may not contain all admin roles
checkMasterAdminManagementRoles(realm); checkMasterAdminManagementRoles(realm);
checkRealmAdminManagementRoles(realm); checkRealmAdminManagementRoles(realm);