summaryrefslogtreecommitdiff
path: root/app
diff options
context:
space:
mode:
authorhttp://jneen.net/ <jneen@jneen.net>2017-07-31 17:09:01 -0700
committerhttp://jneen.net/ <jneen@jneen.net>2017-08-03 09:07:18 -0700
commit3c56e41402301f26bf70afe13d2565e74e4427eb (patch)
tree7db348457d5dc93df23f43ffcc9a54c51c78afa3 /app
parent18288fe21e12bb524757a97472008eabfca5a352 (diff)
downloadgitlab-ce-3c56e41402301f26bf70afe13d2565e74e4427eb.tar.gz
use a simple pluck, since equivalent filtering happens later
Diffstat (limited to 'app')
-rw-r--r--app/services/notification_recipient_service.rb4
1 files changed, 1 insertions, 3 deletions
diff --git a/app/services/notification_recipient_service.rb b/app/services/notification_recipient_service.rb
index 083b5f2d229..7c9bb54f020 100644
--- a/app/services/notification_recipient_service.rb
+++ b/app/services/notification_recipient_service.rb
@@ -175,9 +175,7 @@ module NotificationRecipientService
end
def user_ids_with_global_level_custom(ids, action)
- settings = settings_with_global_level_of(:custom, ids)
- settings = settings.select { |setting| setting.event_enabled?(action) }
- settings.map(&:user_id)
+ settings_with_global_level_of(:custom, ids).pluck(:user_id)
end
def settings_with_global_level_of(level, ids)