From 9493791d1212f484217e74757550353a5ef07dcf Mon Sep 17 00:00:00 2001 From: Richard Macklin Date: Fri, 3 Feb 2017 21:03:26 -0800 Subject: [PATCH] Remove `try` from NotificationService#build_recipients After refactoring pipeline_finished to avoid passing `nil` for current_user, we shouldn't need to use `try` here anymore. --- app/services/notification_service.rb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/app/services/notification_service.rb b/app/services/notification_service.rb index e5283720913..3734e3c4253 100644 --- a/app/services/notification_service.rb +++ b/app/services/notification_service.rb @@ -628,7 +628,7 @@ class NotificationService recipients = reject_unsubscribed_users(recipients, target) recipients = reject_users_without_access(recipients, target) - recipients.delete(current_user) if skip_current_user && !current_user.try(:notified_of_own_activity?) + recipients.delete(current_user) if skip_current_user && !current_user.notified_of_own_activity? recipients.uniq end