Fix cull tripping on nil in last_webfingered_at (#9051)

Fix #8741
This commit is contained in:
Eugen Rochko 2018-10-22 16:58:08 +02:00 committed by GitHub
parent 4bfec4b32d
commit 7f1b063420

View file

@ -223,7 +223,7 @@ module Mastodon
dry_run = options[:dry_run] ? ' (DRY RUN)' : ''
Account.remote.where(protocol: :activitypub).partitioned.find_each do |account|
next if account.updated_at >= skip_threshold || account.last_webfingered_at >= skip_threshold
next if account.updated_at >= skip_threshold || (account.last_webfingered_at.present? && account.last_webfingered_at >= skip_threshold)
unless dead_servers.include?(account.domain)
begin