From afb788218913061a36fad9b14e2e3e34025cc25b Mon Sep 17 00:00:00 2001 From: Claire Date: Mon, 10 May 2021 17:31:55 +0200 Subject: Fix blocking someone not clearing up list feeds (#16205) --- app/services/after_block_service.rb | 5 +++++ 1 file changed, 5 insertions(+) (limited to 'app/services') diff --git a/app/services/after_block_service.rb b/app/services/after_block_service.rb index 314919df8..899e84be4 100644 --- a/app/services/after_block_service.rb +++ b/app/services/after_block_service.rb @@ -6,6 +6,7 @@ class AfterBlockService < BaseService @target_account = target_account clear_home_feed! + clear_list_feeds! clear_notifications! clear_conversations! end @@ -16,6 +17,10 @@ class AfterBlockService < BaseService FeedManager.instance.clear_from_home(@account, @target_account) end + def clear_list_feeds! + FeedManager.instance.clear_from_lists(@account, @target_account) + end + def clear_conversations! AccountConversation.where(account: @account).where('? = ANY(participant_account_ids)', @target_account.id).in_batches.destroy_all end -- cgit