From 276ba773f849a3ce6eaec5bf63f78a1b000b8a01 Mon Sep 17 00:00:00 2001 From: Marcel de Rooy Date: Mon, 19 Aug 2024 11:45:14 +0000 Subject: [PATCH] Bug 37650: Add lookahead days in CheckReserves call in returns.pl Content-Type: text/plain; charset=utf-8 Test plan: Enable future holds. Put a positive value in ConfirmFutureHolds. Add a hold for tomorrow and pickup at B. Check item in at A. Confirm hold. Without this patch you should see a warn on L186: [WARN] Use of uninitialized value in string ne at /usr/share/koha/circ/returns.pl line 186. With this patch, you should not see it anymore. NOTE: Before bug 34972 no transfer was created for future holds. Signed-off-by: Marcel de Rooy --- circ/returns.pl | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/circ/returns.pl b/circ/returns.pl index 9f2e52dab1..67c7b008b8 100755 --- a/circ/returns.pl +++ b/circ/returns.pl @@ -181,7 +181,7 @@ if ( $query->param('reserve_id') && $op eq 'cud-affect_reserve') { } # check if we have other reserves for this document, if we have a result send the message of transfer # FIXME do we need to do this if we didn't take the cancel_reserve branch above? - my ( undef, $nextreservinfo, undef ) = CheckReserves($item); + my ( undef, $nextreservinfo, undef ) = CheckReserves( $item, C4::Context->preference('ConfirmFutureHolds') ); if ( $userenv_branch ne $nextreservinfo->{'branchcode'} ) { my $patron = Koha::Patrons->find( $nextreservinfo->{'borrowernumber'} ); -- 2.39.5