]> cat aescling's git repositories - mastodon.git/commitdiff
Do not hide boost notifications from followed people with hidden boosts (#9147)
authorThibG <thib@sitedethib.com>
Mon, 29 Oct 2018 23:47:31 +0000 (00:47 +0100)
committerEugen Rochko <eugen@zeonfederated.com>
Mon, 29 Oct 2018 23:47:31 +0000 (00:47 +0100)
* Do not hide boost notifications from followed people with hidden boosts

Not displaying boosts from a followed user in the Home timeline and not
having notifications when they reblog your own content are two very
separate concerns, tying them together seem counter-intuitive and unwanted.

* Update specs accordingly

app/services/notify_service.rb
spec/services/notify_service_spec.rb

index 49022a844e9e1fe867e1ff389b92bbfb0649346b..a8b7bb30bae1796d140c0f59a0a47e33d2d89873 100644 (file)
@@ -31,7 +31,7 @@ class NotifyService < BaseService
   end
 
   def blocked_reblog?
-    @recipient.muting_reblogs?(@notification.from_account)
+    false
   end
 
   def blocked_follow_request?
index d3466794314bc653f9e00ad5e89ce7cc00fa3855..39a681abbf70381aaf2cbc69cf05b195ee7a9dd1 100644 (file)
@@ -104,9 +104,9 @@ RSpec.describe NotifyService, type: :service do
       is_expected.to change(Notification, :count)
     end
 
-    it 'hides reblogs when disabled' do
-      recipient.follow!(sender, reblogs: false)
-      is_expected.to_not change(Notification, :count)
+    it 'shows reblogs when disabled' do
+      recipient.follow!(sender, reblogs: true)
+      is_expected.to change(Notification, :count)
     end
   end