This issue has been created
 
 
Publication Workflow Application / cid:jira-generated-image-avatar-32efc262-39cd-4e8e-8b0e-8786db5f0770 XAWORKFLOW-111 Open

Empty rigths objects added when no groups selected for viewer and/or commenter

 
View issue   ยท   Add comment
 

Issue created

 
cid:jira-generated-image-avatar-e81001f5-fe5a-4b12-97ed-becea3a90512 Mathieu Pace created this issue on 10/Jun/24 10:18
 
Summary: Empty rigths objects added when no groups selected for viewer and/or commenter
Issue Type: cid:jira-generated-image-avatar-32efc262-39cd-4e8e-8b0e-8786db5f0770 Improvement
Affects Versions: 2.3.2
Assignee: Unassigned
Created: 10/Jun/24 10:18
Priority: cid:jira-generated-image-static-minor-fde20990-28e0-46a5-836a-455ba20839ec Minor
Reporter: Mathieu Pace
Description:

Reproduction

  1. Create a new workflow and set
    1. Contributors group
    2. Moderators group
    3. Publishers group
    4. leave Viewers group empty
    5. leave Commenters group empty
    6. leave "Skip draft rights update on workflow transition" to No
  2. Create a new page. Set it to be a terminal page. Save it.
  3. Start the workflow on this page (you'll have to display the Workflow Panel first, to be able to click the "Start workflow" button)
  4. Open the page's objects and see:
    1. one XWikiRights object for the groups set for Contributors, Moderators, Publishers
    2. one XWikiRights object with no group set, for granting view rights (corresponding to the Viewers group)
    3. one XWikiRights object with no group set, for granting comment rights (corresponding to the Commenters group)

Note: if not a terminal page, rights will be handled by the WebPreferences page, thus not having the issue

Expectations

There should be no empty XWikiRights objects set

 

The code which sets the rules without checking if a group is set in the workflow is DefaultPublicationWorkflow.java