Bugzilla – Attachment 54268 Details for
Bug 17095
Regression: Error when checking out to non-existent patron
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
[SIGNED-OFF] Bug 17095: (bug 16849 follow-up) Fix regression if patron does not exist
SIGNED-OFF-Bug-17095-bug-16849-follow-up-Fix-regre.patch (text/plain), 1.41 KB, created by
Owen Leonard
on 2016-08-10 12:35:44 UTC
(
hide
)
Description:
[SIGNED-OFF] Bug 17095: (bug 16849 follow-up) Fix regression if patron does not exist
Filename:
MIME Type:
Creator:
Owen Leonard
Created:
2016-08-10 12:35:44 UTC
Size:
1.41 KB
patch
obsolete
>From 471ac38db83d36435e33be7dd27d78bd4b1fa60d Mon Sep 17 00:00:00 2001 >From: Jonathan Druart <jonathan.druart@bugs.koha-community.org> >Date: Tue, 9 Aug 2016 20:08:54 +0100 >Subject: [PATCH] [SIGNED-OFF] Bug 17095: (bug 16849 follow-up) Fix regression > if patron does not exist >Content-Type: text/plain; charset="utf-8" > >Bug 16082, 'Display a friendly "patron does not exist" message if that's the >case - circulation.pl' changed the behavior of the checkout page so that if >you hit that page with a borrowernumber which doesn't exist a nice message will >tell you so. > >Now when you do that you get an error message: > Can't call method "is_debarred" on an undefined value at /circ/circulation.pl line 300. > >Test plan: >confirm that the friendly message is back :) > >Signed-off-by: Owen Leonard <oleonard@myacpl.org> >--- > circ/circulation.pl | 3 ++- > 1 file changed, 2 insertions(+), 1 deletion(-) > >diff --git a/circ/circulation.pl b/circ/circulation.pl >index ed00e2d..dc7d36b 100755 >--- a/circ/circulation.pl >+++ b/circ/circulation.pl >@@ -297,7 +297,8 @@ if ($borrowernumber) { > finetotal => $fines > ); > >- if ( Koha::Patrons->find( $borrowernumber )->is_debarred ) { >+ my $patron = Koha::Patrons->find( $borrowernumber ); >+ if ( $patron and $patron->is_debarred ) { > $template->param( > 'userdebarred' => $borrower->{debarred}, > 'debarredcomment' => $borrower->{debarredcomment}, >-- >2.1.4
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 17095
:
54243
|
54268
|
54391