about summary refs log tree commit diff
path: root/app/services/suspend_account_service.rb
diff options
context:
space:
mode:
authorEugen Rochko <eugen@zeonfederated.com>2018-08-20 13:28:05 +0200
committerGitHub <noreply@github.com>2018-08-20 13:28:05 +0200
commit6226aa83d7eb0e03cc7d577eee1fe129cf0f36fc (patch)
tree8fde90bb7c1ca11141caf4a6af664b4ef2cb33b7 /app/services/suspend_account_service.rb
parent25f6f41052b52a765a74e9e16d7411750ae46221 (diff)
Increase reach of Delete->Actor activities (#8305)
Fix #7316
Diffstat (limited to 'app/services/suspend_account_service.rb')
-rw-r--r--app/services/suspend_account_service.rb8
1 files changed, 5 insertions, 3 deletions
diff --git a/app/services/suspend_account_service.rb b/app/services/suspend_account_service.rb
index 0a98f5fb9..8fc79b8ad 100644
--- a/app/services/suspend_account_service.rb
+++ b/app/services/suspend_account_service.rb
@@ -23,9 +23,7 @@ class SuspendAccountService < BaseService
 
   def purge_content!
     if @account.local?
-      ActivityPub::RawDistributionWorker.perform_async(delete_actor_json, @account.id)
-
-      ActivityPub::DeliveryWorker.push_bulk(Relay.enabled.pluck(:inbox_url)) do |inbox_url|
+      ActivityPub::DeliveryWorker.push_bulk(delivery_inboxes) do |inbox_url|
         [delete_actor_json, @account.id, inbox_url]
       end
     end
@@ -75,4 +73,8 @@ class SuspendAccountService < BaseService
 
     @delete_actor_json = Oj.dump(ActivityPub::LinkedDataSignature.new(payload).sign!(@account))
   end
+
+  def delivery_inboxes
+    Account.inboxes + Relay.enabled.pluck(:inbox_url)
+  end
 end