add icons to auto-reject logs

staging
multiple creatures 2019-07-24 18:27:54 -05:00
parent 88c23ae912
commit c0d23aa032
2 changed files with 3 additions and 3 deletions

View File

@ -61,10 +61,10 @@ module AutorejectHelper
if should_reject?(uri)
if @json
Rails.logger.info("Auto-rejected #{@json['id']} (#{@json['type']})")
LogWorker.perform_async("Auto-rejected an incoming '#{@json['type']}#{@object && " #{@object['type']}".rstrip}' from #{@json['id']}.")
LogWorker.perform_async("\xf0\x9f\x9a\xab Auto-rejected an incoming '#{@json['type']}#{@object && " #{@object['type']}".rstrip}' from #{@json['id']}.")
elsif uri
Rails.logger.info("Auto-rejected #{uri}")
LogWorker.perform_async("Auto-rejected a request to #{uri}.")
LogWorker.perform_async("\xf0\x9f\x9a\xab Auto-rejected a request to #{uri}.")
end
return true
end

View File

@ -184,7 +184,7 @@ class ActivityPub::Activity
def reject_payload!
Rails.logger.info("Rejected #{@json['type']} activity #{@json['id']} from #{@account.uri}#{@options[:relayed_through_account] && "via #{@options[:relayed_through_account].uri}"}")
LogWorker.perform_async("Auto-rejected an incoming '#{@json['type']}#{@object && " #{@object['type']}".rstrip}' from #{@json['id']} by #{@account.uri}#{@options[:relayed_through_account] && " via #{@options[:relayed_through_account].uri}"}.")
LogWorker.perform_async("\xf0\x9f\x9a\xab Auto-rejected an incoming '#{@json['type']}#{@object && " #{@object['type']}".rstrip}' from #{@json['id']} by #{@account.uri}#{@options[:relayed_through_account] && " via #{@options[:relayed_through_account].uri}"}.")
nil
end
end