diff --git a/app/tasks/maintenance/populate_siret_value_json_task.rb b/app/tasks/maintenance/populate_siret_value_json_task.rb index e3f6eacace6..3b43ebb7391 100644 --- a/app/tasks/maintenance/populate_siret_value_json_task.rb +++ b/app/tasks/maintenance/populate_siret_value_json_task.rb @@ -13,6 +13,8 @@ def collection def process(champ) return if champ.etablissement.blank? champ.update!(value_json: APIGeoService.parse_etablissement_address(champ.etablissement)) + rescue ActiveRecord::RecordInvalid + # noop, just a champ without dossier end def count