From: Thomas Berezansky Date: Mon, 30 Jan 2012 13:52:37 +0000 (-0500) Subject: Fix SIP2 "unavailable holds" check X-Git-Tag: sprint4-merge-nov22~4629 X-Git-Url: https://old-git.evergreen-ils.org/?a=commitdiff_plain;h=0ef3b5890df1afb2e533f8c0af60b04389c52d0c;p=working%2FEvergreen.git Fix SIP2 "unavailable holds" check If no IDs, don't look up an empty array of IDs. Signed-off-by: Thomas Berezansky Signed-off-by: Bill Erickson --- diff --git a/Open-ILS/src/perlmods/lib/OpenILS/SIP/Patron.pm b/Open-ILS/src/perlmods/lib/OpenILS/SIP/Patron.pm index 519382ff80..832c827b92 100644 --- a/Open-ILS/src/perlmods/lib/OpenILS/SIP/Patron.pm +++ b/Open-ILS/src/perlmods/lib/OpenILS/SIP/Patron.pm @@ -639,13 +639,14 @@ sub unavail_holds { } }); - my @holds_sip_output = map { + my @holds_sip_output; + @holds_sip_output = map { OpenILS::SIP::clean_text($self->__hold_to_title($_)) } @{ $self->{editor}->search_action_hold_request( {id => [map {$_->{id}} @$ids]} ) - }; + } if (@$ids > 0); return (defined $start and defined $end) ? [ @holds_sip_output[($start-1)..($end-1)] ] :