diff options
author | Thibaut Girka <thib@sitedethib.com> | 2019-02-12 20:32:48 +0100 |
---|---|---|
committer | Thibaut Girka <thib@sitedethib.com> | 2019-02-12 20:32:48 +0100 |
commit | 0e34e91661d47ffbb08121c74c8a2de5266de0c8 (patch) | |
tree | 949024a721989fb2de04de0412cdbdbd41990e36 /app/services | |
parent | a3ba28eb17d75af37396359e8c37675e06605ccf (diff) | |
parent | 2f80a348c9de3de6dbf220f9e12d5906042b3f73 (diff) |
Merge branch 'master' into glitch-soc/merge-upstream
Diffstat (limited to 'app/services')
-rw-r--r-- | app/services/suspend_account_service.rb | 10 |
1 files changed, 9 insertions, 1 deletions
diff --git a/app/services/suspend_account_service.rb b/app/services/suspend_account_service.rb index 1bc2314de..fc3bc03a5 100644 --- a/app/services/suspend_account_service.rb +++ b/app/services/suspend_account_service.rb @@ -102,6 +102,10 @@ class SuspendAccountService < BaseService ActivityPub::DeliveryWorker.push_bulk(delivery_inboxes) do |inbox_url| [delete_actor_json, @account.id, inbox_url] end + + ActivityPub::LowPriorityDeliveryWorker.push_bulk(low_priority_delivery_inboxes) do |inbox_url| + [delete_actor_json, @account.id, inbox_url] + end end def delete_actor_json @@ -117,7 +121,11 @@ class SuspendAccountService < BaseService end def delivery_inboxes - Account.inboxes + Relay.enabled.pluck(:inbox_url) + @delivery_inboxes ||= @account.followers.inboxes + Relay.enabled.pluck(:inbox_url) + end + + def low_priority_delivery_inboxes + Account.inboxes - delivery_inboxes end def associations_for_destruction |