From fc033fa03758b4a1a106b295bb0a0cab2fb00738 Mon Sep 17 00:00:00 2001 From: Kyle M Hall Date: Tue, 27 Mar 2018 10:45:09 -0400 Subject: [PATCH] Bug 18382: (QA follow-up) Don't set suspend_until if dt if undefined Signed-off-by: Jonathan Druart --- Koha/Hold.pm | 6 +----- 1 file changed, 1 insertion(+), 5 deletions(-) diff --git a/Koha/Hold.pm b/Koha/Hold.pm index acb5adedb0..e76b9fb17e 100644 --- a/Koha/Hold.pm +++ b/Koha/Hold.pm @@ -91,11 +91,7 @@ sub suspend_hold { } $self->suspend(1); - if ( defined $dt ){ - $self->suspend_until( $dt->datetime ); - } else { - $self->suspend_until( $dt ); - } + $self->suspend_until( $dt->datetime ) if ( defined $dt ); $self->store(); logaction( 'HOLDS', 'SUSPEND', $self->reserve_id, Dumper($self->unblessed) ) -- 2.39.5