https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=29474 Joonas Kylmälä <joonas.kylmala@iki.fi> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |joonas.kylmala@iki.fi --- Comment #2 from Joonas Kylmälä <joonas.kylmala@iki.fi> --- If you remove the unless then you can delete the line
return ( 0, "on_reserve" ) if $resfound && $cron; # '' when no hold was found
Makes the code much simpler. Please also move the cron return right after the call to
$auto_renew = _CanBookBeAutoRenewed({
so that now that the return value decision is not in an if-else condition at the end the requirement for returning the values in a different order is clear and the order won't be changed by some other developer accidentally. I think adding a comment like "cron wants 'too_soon' over 'on_reserve'" Please include stats too, but maybe you are at it, I noticed that this bug is not even yet for sign-off and I'm here reviewing ;D -- You are receiving this mail because: You are watching all bug changes. You are the assignee for the bug.