Bugzilla – Attachment 187208 Details for
Bug 40929
Can't call method "borrowernumber" on an undefined value at opac-modrequest.pl
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
Bug 40929: Add $hold test in opac-modrequest
Bug-40929-Add-hold-test-in-opac-modrequest.patch (text/plain), 1.11 KB, created by
Tomás Cohen Arazi (tcohen)
on 2025-10-01 15:25:54 UTC
(
hide
)
Description:
Bug 40929: Add $hold test in opac-modrequest
Filename:
MIME Type:
Creator:
Tomás Cohen Arazi (tcohen)
Created:
2025-10-01 15:25:54 UTC
Size:
1.11 KB
patch
obsolete
>From c13e245409062deece6624779bbd8e934cb5ff11 Mon Sep 17 00:00:00 2001 >From: Marcel de Rooy <m.de.rooy@rijksmuseum.nl> >Date: Wed, 1 Oct 2025 16:34:38 +0200 >Subject: [PATCH] Bug 40929: Add $hold test in opac-modrequest >MIME-Version: 1.0 >Content-Type: text/plain; charset=UTF-8 >Content-Transfer-Encoding: 8bit > >Test plan: >Login at OPAC. >Pass an unexisting reserve_id in a opac-modrequest.pl URL. >Verify that you get a 403 redirect. > >Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl> >Signed-off-by: Tomás Cohen Arazi <tomascohen@theke.io> >--- > opac/opac-modrequest.pl | 2 +- > 1 file changed, 1 insertion(+), 1 deletion(-) > >diff --git a/opac/opac-modrequest.pl b/opac/opac-modrequest.pl >index de61d61a12..2cf6712685 100755 >--- a/opac/opac-modrequest.pl >+++ b/opac/opac-modrequest.pl >@@ -46,7 +46,7 @@ if ( $reserve_id && $borrowernumber ) { > > my $hold = Koha::Holds->find($reserve_id); > >- unless ( $hold->borrowernumber == $borrowernumber ) { >+ unless ( $hold && $hold->borrowernumber == $borrowernumber ) { > > # whatcha tryin to do? > print $query->redirect('/cgi-bin/koha/errors/403.pl'); >-- >2.51.0
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Actions:
View
|
Diff
|
Splinter Review
Attachments on
bug 40929
:
187199
| 187208