LP#1053397 MR holds placement cont.
authorBill Erickson <berick@esilibrary.com>
Fri, 31 Jan 2014 15:03:18 +0000 (10:03 -0500)
committerBill Erickson <berick@esilibrary.com>
Fri, 31 Jan 2014 15:03:18 +0000 (10:03 -0500)
Signed-off-by: Bill Erickson <berick@esilibrary.com>
Open-ILS/src/perlmods/lib/OpenILS/Application/Circ/Holds.pm

index bb7ed2c..00a0da1 100644 (file)
@@ -92,12 +92,14 @@ sub test_and_create_hold_batch {
     elsif ($$params{'hold_type'} eq 'P') { $target_field = 'partid'; }
     else { return undef; }
 
+    my $formats_map = delete $$params{holdable_formats_map};
+
     foreach (@$target_list) {
         $$params{$target_field} = $_;
 
         # copy the requested formats from the target->formats map
         # into the top-level formats attr for each hold
-        $$params{holdable_formats} = $$params{holdable_formats_map}{$_};
+        $$params{holdable_formats} = $formats_map->{$_};
 
         my $res;
         ($res) = $self->method_lookup(