Skip to content

Commit db953d0

Browse files
committed
Added: explanatory comment to PermissionServiceBean.getEffectiveRoleAssignments
1 parent e6f4221 commit db953d0

1 file changed

Lines changed: 6 additions & 0 deletions

File tree

src/main/java/edu/harvard/iq/dataverse/PermissionServiceBean.java

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -964,6 +964,12 @@ public List<Dataverse> findPermittedCollections(DataverseRequest request, Authen
964964
* Calculates the complete list of role assignments for a given user on a DvObject.
965965
* This includes roles assigned directly to the user and roles inherited from any groups
966966
* the user is a member of.
967+
* <p>
968+
* This method's logic is based on the private method {@code getRoleStringFromUser}
969+
* in the {@code DataverseUserPage} class, which produces a concatenated string of
970+
* effective user role names required for displaying role-related user notifications.
971+
* The common logic from these two methods may be centralized in the future to
972+
* avoid code duplication.
967973
*
968974
* @param user The authenticated user whose roles are being checked.
969975
* @param dvObject The dataverse object to check for role assignments.

0 commit comments

Comments
 (0)