Skip to content
Snippets Groups Projects
Commit 58ecb06f authored by Douwe Maan's avatar Douwe Maan
Browse files

Remove duplicates from group milestone participants list.

parent 0a9cab4e
Branches
Tags
No related merge requests found
Loading
@@ -49,7 +49,7 @@ v 7.8.0
Loading
@@ -49,7 +49,7 @@ v 7.8.0
- -
- Add action property to merge request hook (Julien Bianchi) - Add action property to merge request hook (Julien Bianchi)
- -
- - Remove duplicates from group milestone participants list.
- -
- -
- Add a new API function that retrieves all issues assigned to a single milestone (Justin Whear and Hannes Rosenögger) - Add a new API function that retrieves all issues assigned to a single milestone (Justin Whear and Hannes Rosenögger)
Loading
Loading
Loading
@@ -66,15 +66,15 @@ class GroupMilestone
Loading
@@ -66,15 +66,15 @@ class GroupMilestone
end end
   
def issues def issues
@group_issues ||= milestones.map { |milestone| milestone.issues }.flatten.group_by(&:state) @group_issues ||= milestones.map(&:issues).flatten.group_by(&:state)
end end
   
def merge_requests def merge_requests
@group_merge_requests ||= milestones.map { |milestone| milestone.merge_requests }.flatten.group_by(&:state) @group_merge_requests ||= milestones.map(&:merge_requests).flatten.group_by(&:state)
end end
   
def participants def participants
milestones.map { |milestone| milestone.participants.uniq }.reject(&:empty?).flatten @group_participants ||= milestones.map(&:participants).flatten.compact.uniq
end end
   
def opened_issues def opened_issues
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment