diff options
Diffstat (limited to 'app/models/notification_setting.rb')
-rw-r--r-- | app/models/notification_setting.rb | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/app/models/notification_setting.rb b/app/models/notification_setting.rb index 2b3443f24d7..1447f822513 100644 --- a/app/models/notification_setting.rb +++ b/app/models/notification_setting.rb @@ -21,7 +21,10 @@ class NotificationSetting < ApplicationRecord # pending delete). # scope :for_projects, -> do - includes(:project).references(:projects).where(source_type: 'Project').where.not(projects: { id: nil, pending_delete: true }) + includes(:project).references(:projects) + .where(source_type: 'Project') + .where.not(projects: { id: nil }) + .where.not(projects: { pending_delete: true }) end EMAIL_EVENTS = [ |