fix(task): use dossier.read_attribute instead of direct read

This commit is contained in:
Paul Chavard 2021-12-07 13:36:59 +01:00
parent 5615baa985
commit 612b3bd82d

View file

@ -7,7 +7,7 @@ namespace :after_party do
progress = ProgressReport.new(dossiers.count)
dossiers.find_each do |dossier|
if dossier.processed_at != dossier.traitement.processed_at
if dossier.read_attribute(:processed_at) != dossier.traitement.processed_at
dossier.update_column(:processed_at, dossier.traitement.processed_at)
end
progress.inc