Simplify invited_group_members filter-by-level
This commit is contained in:
parent
e4485d7b68
commit
e2c2bd69f2
1 changed files with 6 additions and 6 deletions
|
@ -244,12 +244,12 @@ class ProjectTeam
|
|||
next if numeric_level > link.group_access
|
||||
|
||||
# Make sure we include everyone _above_ the requested level as well
|
||||
if numeric_level == link.group_access
|
||||
invited_group_members = invited_group_members
|
||||
.where("access_level >= ?", link.group_access)
|
||||
else
|
||||
invited_group_members = invited_group_members.public_send(level)
|
||||
end
|
||||
invited_group_members =
|
||||
if numeric_level == link.group_access
|
||||
invited_group_members.where("access_level >= ?", link.group_access)
|
||||
else
|
||||
invited_group_members.public_send(level)
|
||||
end
|
||||
end
|
||||
|
||||
invited_members << invited_group_members
|
||||
|
|
Loading…
Reference in a new issue