diff options
author | Adam Niedzielski <adamsunday@gmail.com> | 2016-08-04 07:59:14 +0200 |
---|---|---|
committer | Adam Niedzielski <adamsunday@gmail.com> | 2016-08-04 07:59:14 +0200 |
commit | 419990ebd2a9f4781d625b1f234be04271c36ac6 (patch) | |
tree | 3a7054e5d000c3641fcbe1ab864c801ded1d887a /app/models/member.rb | |
parent | d0aa98bc5dc7228415f1eba2f61f75fa6406180a (diff) | |
download | gitlab-ce-419990ebd2a9f4781d625b1f234be04271c36ac6.tar.gz |
Remove scopes.
Diffstat (limited to 'app/models/member.rb')
-rw-r--r-- | app/models/member.rb | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/app/models/member.rb b/app/models/member.rb index 9d913805ad2..bcb6e32d53a 100644 --- a/app/models/member.rb +++ b/app/models/member.rb @@ -31,7 +31,6 @@ class Member < ActiveRecord::Base scope :non_invite, -> { where(invite_token: nil) } scope :request, -> { where.not(requested_at: nil) } scope :has_access, -> { where('access_level > 0') } - scope :still_active, -> { where('expires_at IS NULL OR expires_at > ?', Time.current) } scope :guests, -> { where(access_level: GUEST) } scope :reporters, -> { where(access_level: REPORTER) } @@ -55,7 +54,7 @@ class Member < ActiveRecord::Base class << self def access_for_user_ids(user_ids) - where(user_id: user_ids).has_access.still_active.pluck(:user_id, :access_level).to_h + where(user_id: user_ids).has_access.pluck(:user_id, :access_level).to_h end def find_by_invite_token(invite_token) |