Bug 12556: Reuse code from Koha::Hold instead of duplicating it

Signed-off-by: Timothy Alexis Vass <timothy_alexis.vass@ub.lu.se>
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>

Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
This commit is contained in:
Joonas Kylmälä 2020-07-22 15:44:31 +00:00 committed by Jonathan Druart
parent bb3e76f7f9
commit 01eebf333d
1 changed files with 1 additions and 4 deletions

View File

@ -567,10 +567,7 @@ sub CanReserveBeCanceledFromOpac {
my $reserve = Koha::Holds->find($reserve_id);
return 0 unless $reserve->borrowernumber == $borrowernumber;
return 0 if ( $reserve->found eq 'W' ) or ( $reserve->found eq 'T' );
return 1;
return $reserve->is_cancelable_from_opac;
}
=head2 GetOtherReserves