From 98b3b80d6bc6b8549448bb7fadc1449ba68a52ea Mon Sep 17 00:00:00 2001 From: Eugen Rochko Date: Mon, 13 Jul 2020 19:33:10 +0200 Subject: [PATCH] Fix account domain block not properly unfollowing accounts from domain (#14304) Fix #14303 --- app/services/after_block_domain_from_account_service.rb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/app/services/after_block_domain_from_account_service.rb b/app/services/after_block_domain_from_account_service.rb index f50bde261d2..89d007c1cd9 100644 --- a/app/services/after_block_domain_from_account_service.rb +++ b/app/services/after_block_domain_from_account_service.rb @@ -19,7 +19,7 @@ class AfterBlockDomainFromAccountService < BaseService private def remove_follows! - @account.active_relationships.where(account: Account.where(domain: @domain)).includes(:target_account).reorder(nil).find_each do |follow| + @account.active_relationships.where(target_account: Account.where(domain: @domain)).includes(:target_account).reorder(nil).find_each do |follow| UnfollowService.new.call(@account, follow.target_account) end end