Bug 21729: Simplify non-existent expiration date

No change in behaviour expected by this patch.

Signed-off-by: Andrew Fuerste-Henry <andrew@bywatersolutions.com>
Signed-off-by: Florian Bontemps <florian.bontemps@biblibre.com>
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com>
This commit is contained in:
Jonathan Druart 2021-10-14 08:38:02 +02:00 committed by Fridolin Somers
parent b52f9adf08
commit baeea4533c

View file

@ -596,8 +596,7 @@ sub store {
if (
C4::Context->preference('DefaultHoldExpirationdate')
and ( not defined $self->expirationdate
or $self->expirationdate eq '' )
&& !$self->expirationdate
)
{
$self->_set_default_expirationdate;
@ -611,9 +610,7 @@ sub store {
if ( exists $updated_columns{reservedate} ) {
if (
C4::Context->preference('DefaultHoldExpirationdate')
and ( not exists $updated_columns{expirationdate}
or exists $updated_columns{expirationdate}
and $updated_columns{expirationdate} eq '' )
&& ! exists $updated_columns{expirationdate}
)
{
$self->_set_default_expirationdate;