Bug 27065 - Automatic renewals performed when no reservable items are available but items that can be issued are available.
Summary: Automatic renewals performed when no reservable items are available but items...
Status: RESOLVED DUPLICATE of bug 26659
Alias: None
Product: Koha
Classification: Unclassified
Component: Circulation (show other bugs)
Version: 20.05
Hardware: All All
: P5 - low major
Assignee: Bugs List
QA Contact: Testopia
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2020-11-20 11:58 UTC by Andreas Jonsson
Modified: 2020-11-20 13:44 UTC (History)
3 users (show)

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


Attachments
Bug 27065: Fix incorrect handling of return value of CanItemBeRenewed in CanBookBeRenewed (1.05 KB, patch)
2020-11-20 12:03 UTC, Andreas Jonsson
Details | Diff | Splinter Review

Note You need to log in before you can comment on or make changes to this bug.
Description Andreas Jonsson 2020-11-20 11:58:32 UTC
The return value of CanItemBeReserved is incorrectly used in a condition in CanBookBeRenewed:


                    next unless CanItemBeReserved($borrowernumber,$itemnumber);

CanItemBeReserved returns a hash reference wich always evaluates to true.  The condition should instead be:

                    next unless CanItemBeReserved($borrowernumber,$itemnumber)->{status} eq 'OK';
Comment 1 Andreas Jonsson 2020-11-20 12:03:54 UTC
Created attachment 113879 [details] [review]
Bug 27065: Fix incorrect handling of return value of CanItemBeRenewed in CanBookBeRenewed
Comment 2 Jonathan Druart 2020-11-20 13:44:57 UTC
Please have a look at bug 26659.

*** This bug has been marked as a duplicate of bug 26659 ***