Bug 17095 - Regression: Error when checking out to non-existent patron
Summary: Regression: Error when checking out to non-existent patron
Status: CLOSED FIXED
Alias: None
Product: Koha
Classification: Unclassified
Component: Circulation (show other bugs)
Version: Main
Hardware: All All
: P5 - low normal (vote)
Assignee: Jonathan Druart
QA Contact: Testopia
URL: /cgi-bin/koha/circ/circulation.pl?bor...
Keywords:
Depends on:
Blocks:
 
Reported: 2016-08-09 18:47 UTC by Owen Leonard
Modified: 2017-12-07 22:17 UTC (History)
3 users (show)

See Also:
Change sponsored?: ---
Patch complexity: Trivial patch
Documentation contact:
Documentation submission:
Text to go in the release notes:
Version(s) released in:


Attachments
Bug 17095: (bug 16849 follow-up) Fix regression if patron does not exist (1.31 KB, patch)
2016-08-09 19:10 UTC, Jonathan Druart
Details | Diff | Splinter Review
[SIGNED-OFF] Bug 17095: (bug 16849 follow-up) Fix regression if patron does not exist (1.41 KB, patch)
2016-08-10 12:35 UTC, Owen Leonard
Details | Diff | Splinter Review
Bug 17095: (bug 16849 follow-up) Fix regression if patron does not exist (1.41 KB, patch)
2016-08-12 17:47 UTC, Nick Clemens
Details | Diff | Splinter Review

Note You need to log in before you can comment on or make changes to this bug.
Description Owen Leonard 2016-08-09 18:47:03 UTC
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.

git bisect blames Bug 16849, 'Move IsDebarred to Koha::Patron->is_debarred'
Comment 1 Jonathan Druart 2016-08-09 19:10:58 UTC Comment hidden (obsolete)
Comment 2 Owen Leonard 2016-08-10 12:35:44 UTC Comment hidden (obsolete)
Comment 3 Nick Clemens 2016-08-12 17:47:25 UTC
Created attachment 54391 [details] [review]
Bug 17095: (bug 16849 follow-up) Fix regression if patron does not exist

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>

Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
Comment 4 Kyle M Hall 2016-08-18 16:04:07 UTC
Pushed to master for 16.11, thanks Jonathan!