This issue has been created
 
 
XWiki Platform / cid:jira-generated-image-avatar-8630e9ca-9ef5-4d0b-bcd8-1b837767382c XWIKI-22786 Open

Update or mark method User#isUserInGroup as deprecated

 
View issue   ยท   Add comment
 

Issue created

 
cid:jira-generated-image-avatar-c4617c82-b90d-4458-91a4-46845c33324e Anca Luca created this issue on 15/Jan/25 23:57
 
Summary: Update or mark method User#isUserInGroup as deprecated
Issue Type: cid:jira-generated-image-avatar-8630e9ca-9ef5-4d0b-bcd8-1b837767382c Improvement
Affects Versions: 16.4.6
Assignee: Unassigned
Components: User
Created: 15/Jan/25 23:57
Labels: Documentation
Priority: cid:jira-generated-image-static-major-cdaea7fe-5a61-4817-a7c1-99a2b4bb3b70 Major
Reporter: Anca Luca
Description:

The method from isUserInGroup from com.xpn.xwiki.api.User is using deprecated API to fetch the user's group list, instead of the new group manager API methods.

Issue XWIKI-12292 open about this method is closed as won't fix with a recommendation to use the group manager API instead.

Thus, one of the 2 needs to be done:

  • either the method isUserInGroup is kept but marked somehow as deprecated, or javadoc is updated to mention that it has unresolved limitations and the group manager API is now recommended
  • or its implementation is updated to be as correct as it can be using the latest and greatest of the APIs.