mirror of
https://github.com/internetee/registry.git
synced 2025-06-07 13:15:40 +02:00
add update instead save
This commit is contained in:
parent
ac9b6c23bf
commit
ec90722bf0
2 changed files with 2 additions and 4 deletions
|
@ -23,8 +23,7 @@ class MigrateBeforeForceDeleteStatusesJob < ApplicationJob
|
|||
end
|
||||
|
||||
def migrate_data_to_statuses_history(domain)
|
||||
domain.force_delete_domain_statuses_history = domain.statuses_before_force_delete
|
||||
domain.save
|
||||
domain.update(force_delete_domain_statuses_history: domain.statuses_before_force_delete)
|
||||
rescue StandardError => e
|
||||
logger.warn "#{domain.name} crashed!"
|
||||
logger.warn e.to_s
|
||||
|
|
|
@ -23,8 +23,7 @@ class MigrateStatusesToDomainHistoryJob < ApplicationJob
|
|||
end
|
||||
|
||||
def migrate_data_to_admin_store_field(domain)
|
||||
domain.admin_store_statuses_history = domain.statuses
|
||||
domain.save
|
||||
domain.update(admin_store_statuses_history: domain.statuses)
|
||||
rescue StandardError => e
|
||||
logger.warn "#{domain.name} crashed!"
|
||||
logger.warn e.to_s
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue