diff options
author | multiple creatures <dev@multiple-creature.party> | 2019-12-03 17:01:09 -0600 |
---|---|---|
committer | multiple creatures <dev@multiple-creature.party> | 2019-12-03 17:06:47 -0600 |
commit | e63192cbb10eb2aabb13b919adecbea5d1317693 (patch) | |
tree | f8fbeac4807e224cafd19e8886577db02fcda94c /app | |
parent | 04ec25754b98be080114c9f121b66d7def6de2b5 (diff) |
clear filtered status cache when a domain policy gets reset
Diffstat (limited to 'app')
-rw-r--r-- | app/services/unblock_domain_service.rb | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/app/services/unblock_domain_service.rb b/app/services/unblock_domain_service.rb index ec6723421..854daf0ac 100644 --- a/app/services/unblock_domain_service.rb +++ b/app/services/unblock_domain_service.rb @@ -6,6 +6,7 @@ class UnblockDomainService < BaseService def call(domain_block, destroy_domain_block = true) @domain_block = domain_block process_retroactive_updates + clear_filtered_status_cache domain_block.destroy if destroy_domain_block end @@ -16,6 +17,11 @@ class UnblockDomainService < BaseService end end + def clear_filtered_status_cache + keys = redis.keys("filtered_statuses:*") + redis.del(*keys) unless keys.empty? + end + def blocked_accounts scope = Account.where(domain: domain_block.domain) if domain_block.silence? |