mirror of
https://github.com/internetee/registry.git
synced 2025-07-30 06:26:15 +02:00
refactoring
This commit is contained in:
parent
bc0a9d4f99
commit
eb35140fe4
2 changed files with 2 additions and 9 deletions
|
@ -62,8 +62,7 @@ module Actions
|
|||
output_a_and_aaaa_validation_results(email: @email,
|
||||
result: result_validation,
|
||||
type: 'AAAA')
|
||||
|
||||
result_validation.present? ? result.success = true : result.success = false
|
||||
result.success = result_validation.present?
|
||||
end
|
||||
|
||||
contacts.find_in_batches(batch_size: 500) do |contact_batches|
|
||||
|
|
|
@ -48,12 +48,6 @@ class VerifyEmailsJob < ApplicationJob
|
|||
data = contact.validation_events.order(created_at: :asc).last
|
||||
return true if data.successful? && data.created_at < (Time.zone.now - ValidationEvent::VALIDATION_PERIOD)
|
||||
|
||||
if data.failed?
|
||||
return false if data.event_data['check_level'] == 'regex'
|
||||
|
||||
return true
|
||||
end
|
||||
|
||||
false
|
||||
!(data.failed? && data.event_data['check_level'] == 'regex')
|
||||
end
|
||||
end
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue