Merge pull request #7947 from betagouv/raise_if_update_fail_in_merge

fix(silent_error_in_merge): leve une exception si une mise a jour dans l'update échoue
This commit is contained in:
LeSim 2022-10-26 23:36:25 +02:00 committed by GitHub
commit 8f76b7188c
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -131,7 +131,7 @@ class Administrateur < ApplicationRecord
old_service.procedures.update_all(service_id: corresponding_service.id)
old_service.destroy
else
old_service.update(administrateur_id: id)
old_service.update!(administrateur_id: id)
end
end