Correct CDBI thinko -- search_where is smart about wantarray, search is not
authorMike Rylander <mrylander@gmail.com>
Thu, 14 Jul 2011 15:42:26 +0000 (11:42 -0400)
committerMike Rylander <mrylander@gmail.com>
Thu, 14 Jul 2011 15:45:17 +0000 (11:45 -0400)
Signed-off-by: Mike Rylander <mrylander@gmail.com>
Open-ILS/src/perlmods/lib/OpenILS/Application/Storage/Publisher/action.pm

index ca1e0df..23717a7 100644 (file)
@@ -1271,7 +1271,7 @@ sub new_hold_copy_targeter {
                                                isTrue($_->holdable) &&
                                                !isTrue($_->deleted) &&
                                                (isTrue($hold->mint_condition) ? isTrue($_->mint_condition) : 1) &&
-                                               ($hold->hold_type ne 'P' ? @{ $_->part_maps } == 0 : 1)
+                                               ($hold->hold_type ne 'P' ? $_->part_maps->count == 0 : 1)
                                        } @$all_copies;
 
                        # let 'em know we're still working