BasicModel.hasRole mistakenly invokes inheritPrivledges on Identities that do NOT have the role. This causes two issues:
-
Privledges are not inherited for identities that have the role.
-
Worse when attempting to inherit privledges for identities that do not possess the role and 15 second delay will be occur.
Code in question: boolean hasRole = !query.getResultList().isEmpty();
if (!hasRole) { return relationshipManager.inheritsPrivileges(assignee, role); }
The conditional with bang sign (NOT) should have it removed.
|