From bf27f256c53a7843aa6393a2d2dcb114a48bbe8b Mon Sep 17 00:00:00 2001 From: multiple creatures Date: Wed, 24 Jul 2019 20:04:29 -0500 Subject: clarify rejected announces correctly (but even more correctly with the right json object) --- app/helpers/autoreject_helper.rb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'app/helpers') diff --git a/app/helpers/autoreject_helper.rb b/app/helpers/autoreject_helper.rb index 3ddbad63d..6f010ca96 100644 --- a/app/helpers/autoreject_helper.rb +++ b/app/helpers/autoreject_helper.rb @@ -12,7 +12,7 @@ module AutorejectHelper domain = uri.scan(/[\w\-]+\.[\w\-]+(?:\.[\w\-]+)*/).first blocks = DomainBlock.suspend - reason = ((@object && @object['type'] == 'Announce') ? :domain_boosted : :domain) + reason = ((@json && @json['type'] == 'Announce') ? :domain_boost : :domain) return reason if blocks.where(domain: domain).or(blocks.where('domain LIKE ?', "%.#{domain}")).exists? return unless @json || @object -- cgit