about summary refs log tree commit diff
path: root/app/models
diff options
context:
space:
mode:
authorReverite <github@reverite.sh>2019-06-22 14:15:02 -0600
committerReverite <github@reverite.sh>2019-06-22 14:15:02 -0600
commit714940de498e93a8bf40dcda1835217df18741bf (patch)
treeeafc1d01710ba978f133216d8d1a6e4d585606c6 /app/models
parentb2ffaa9f2909c83f23691a02b2843bf41a1a12c0 (diff)
parent38d28824475056766c97385b66f4e04a5123e3a2 (diff)
Merge branch 'glitch' into production
Diffstat (limited to 'app/models')
-rw-r--r--app/models/user.rb2
1 files changed, 1 insertions, 1 deletions
diff --git a/app/models/user.rb b/app/models/user.rb
index c24741ff1..fcfb79612 100644
--- a/app/models/user.rb
+++ b/app/models/user.rb
@@ -88,7 +88,7 @@ class User < ApplicationRecord
   scope :confirmed, -> { where.not(confirmed_at: nil) }
   scope :enabled, -> { where(disabled: false) }
   scope :inactive, -> { where(arel_table[:current_sign_in_at].lt(ACTIVE_DURATION.ago)) }
-  scope :active, -> { confirmed.where(arel_table[:current_sign_in_at].gteq(ACTIVE_DURATION.ago)).joins(:account).where.not(accounts: { suspended_at: nil }) }
+  scope :active, -> { confirmed.where(arel_table[:current_sign_in_at].gteq(ACTIVE_DURATION.ago)).joins(:account).where(accounts: { suspended_at: nil }) }
   scope :matches_email, ->(value) { where(arel_table[:email].matches("#{value}%")) }
   scope :emailable, -> { confirmed.enabled.joins(:account).merge(Account.searchable) }