about summary refs log tree commit diff
path: root/app/services/reblog_service.rb
diff options
context:
space:
mode:
authorEugen Rochko <eugen@zeonfederated.com>2017-09-01 21:26:01 +0200
committerGitHub <noreply@github.com>2017-09-01 21:26:01 +0200
commit390bfec6da74218e2ebd4eea16dff586b25177d9 (patch)
treeef2284c5afd6cef15c7b1baec18927a091c08fe4 /app/services/reblog_service.rb
parentc2980d5b17d355985a6d5ac4eaa12371463363b3 (diff)
Avoid sending some ActivityPub payloads if the receiver will get them through distribution (#4739)
Diffstat (limited to 'app/services/reblog_service.rb')
-rw-r--r--app/services/reblog_service.rb2
1 files changed, 1 insertions, 1 deletions
diff --git a/app/services/reblog_service.rb b/app/services/reblog_service.rb
index 5ed16c64b..3c4e5847f 100644
--- a/app/services/reblog_service.rb
+++ b/app/services/reblog_service.rb
@@ -36,7 +36,7 @@ class ReblogService < BaseService
       NotifyService.new.call(reblogged_status.account, reblog)
     elsif reblogged_status.account.ostatus?
       NotificationWorker.perform_async(stream_entry_to_xml(reblog.stream_entry), reblog.account_id, reblogged_status.account_id)
-    elsif reblogged_status.account.activitypub?
+    elsif reblogged_status.account.activitypub? && !reblogged_status.account.following?(reblog.account)
       ActivityPub::DeliveryWorker.perform_async(build_json(reblog), reblog.account_id, reblogged_status.account.inbox_url)
     end
   end