https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=26659 Bug ID: 26659 Summary: An item can be renewed even if there are holds waiting to be filled Change sponsored?: --- Product: Koha Version: master Hardware: All OS: All Status: NEW Severity: normal Priority: P5 - low Component: Circulation Assignee: koha-bugs@lists.koha-community.org Reporter: joonas.kylmala@helsinki.fi QA Contact: testopia@bugs.koha-community.org CC: gmcharlt@gmail.com, kyle.m.hall@gmail.com I'm not quite sure how to exactly reproduce the issue but if you have - AllowRenewalIfOtherItemsAvailable enabled - all the books are checked out - there is a hold to the biblio then the people having checked out items can renew their loans for the item they have even though it should not be possible because when there is a hold and no available items then no renewals should be allowed in order to make the patrons return the item and let the person having the hold be able to checkout the item. The culprit seems to be the following line in C4/Circulation.pm:
next unless CanItemBeReserved($borrowernumber,$itemnumber);
It should be corrected to
next unless CanItemBeReserved($borrowernumber,$itemnumber)->{status} eq 'OK';
-- You are receiving this mail because: You are watching all bug changes. You are the assignee for the bug.