about summary refs log tree commit diff
path: root/app/services/suspend_account_service.rb
diff options
context:
space:
mode:
authorThibaut Girka <thib@sitedethib.com>2018-08-21 18:24:48 +0200
committerThibaut Girka <thib@sitedethib.com>2018-08-21 18:24:48 +0200
commit8b4abaa90d8dff64525d92c3ba1c750356608240 (patch)
tree51f194442d2ec7ab760b443b98c7685f64481ca7 /app/services/suspend_account_service.rb
parentc78918162642649ce294d89effbf2e815c2aa327 (diff)
parentf06fa099625e928e5858ea81a20be1eddf6c6fbb (diff)
Merge branch 'master' into glitch-soc/master
Conflicts:
	config/routes.rb

Added the “endorsements” route from upstream.
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