]> cat aescling's git repositories - mastodon.git/commitdiff
Fix #4172 - Mutes now block notifications (#4300)
authorEugen Rochko <eugen@zeonfederated.com>
Sat, 22 Jul 2017 14:36:36 +0000 (16:36 +0200)
committerGitHub <noreply@github.com>
Sat, 22 Jul 2017 14:36:36 +0000 (16:36 +0200)
app/services/notify_service.rb

index a44df518031834a45710b43b270830b25393ba58..ca53c61c50ecbc21a27d43678ba487edbcca8db1 100644 (file)
@@ -21,7 +21,7 @@ class NotifyService < BaseService
   end
 
   def blocked_favourite?
-    @recipient.muting?(@notification.from_account)
+    false
   end
 
   def blocked_follow?
@@ -41,6 +41,7 @@ class NotifyService < BaseService
     blocked ||= @recipient.id == @notification.from_account.id                                                                       # Skip for interactions with self
     blocked ||= @recipient.domain_blocking?(@notification.from_account.domain) && !@recipient.following?(@notification.from_account) # Skip for domain blocked accounts
     blocked ||= @recipient.blocking?(@notification.from_account)                                                                     # Skip for blocked accounts
+    blocked ||= @recipient.muting?(@notification.from_account)                                                                       # Skip for muted accounts
     blocked ||= (@notification.from_account.silenced? && !@recipient.following?(@notification.from_account))                         # Hellban
     blocked ||= (@recipient.user.settings.interactions['must_be_follower']  && !@notification.from_account.following?(@recipient))   # Options
     blocked ||= (@recipient.user.settings.interactions['must_be_following'] && !@recipient.following?(@notification.from_account))   # Options