From 5dd25fd1b66a0b59b0e885af3a766d50d4900f4d Mon Sep 17 00:00:00 2001 From: Paul Chavard Date: Tue, 10 Dec 2024 11:20:29 +0100 Subject: [PATCH] fix(champ): bypass blank? implementation when champ is not in revision --- app/models/champ.rb | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/app/models/champ.rb b/app/models/champ.rb index 5a9e79520..1062221dc 100644 --- a/app/models/champ.rb +++ b/app/models/champ.rb @@ -89,7 +89,8 @@ class Champ < ApplicationRecord end def blank? - type_de_champ.champ_blank?(self) + # FIXME: temporary fix to avoid breaking validation + in_dossier_revision? ? type_de_champ.champ_blank?(self) : value.blank? end def used_by_routing_rules?