fix User.potential_team_members
This commit is contained in:
parent
8016a7bd33
commit
70e05801b1
1 changed files with 1 additions and 1 deletions
|
@ -91,7 +91,7 @@ class User < ActiveRecord::Base
|
|||
scope :alphabetically, order('name ASC')
|
||||
scope :in_team, ->(team){ where(id: team.member_ids) }
|
||||
scope :not_in_team, ->(team){ where('users.id NOT IN (:ids)', ids: team.member_ids) }
|
||||
scope :potential_team_members, ->(team) { team.members.any? ? active : active.not_in_team(team) }
|
||||
scope :potential_team_members, ->(team) { team.members.any? ? active.not_in_team(team) : active }
|
||||
|
||||
#
|
||||
# Class methods
|
||||
|
|
Loading…
Reference in a new issue