Skip to content

Commit

Permalink
TRUNK-6267: Fixing the java.util.ConcurrentModificationException on h…
Browse files Browse the repository at this point in the history
…asPrivilege method (#4750)
  • Loading branch information
wikumChamith committed Sep 19, 2024
1 parent bc725f2 commit 83e1ef4
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion api/src/main/java/org/openmrs/api/context/UserContext.java
Original file line number Diff line number Diff line change
Expand Up @@ -325,7 +325,7 @@ public Set<Role> getAllRoles(User user) throws Exception {
public boolean hasPrivilege(String privilege) {
log.debug("Checking '{}' against proxies: {}", privilege, proxies);
// check proxied privileges
for (String s : proxies) {
for (String s : new ArrayList<>(proxies)) {
if (s.equals(privilege)) {
notifyPrivilegeListeners(getAuthenticatedUser(), privilege, true);
return true;
Expand Down

0 comments on commit 83e1ef4

Please sign in to comment.