Fix currently harmless but still confusing sigil error
authorDan Wells <dbw2@calvin.edu>
Mon, 7 Jul 2014 17:16:58 +0000 (13:16 -0400)
committerDan Wells <dbw2@calvin.edu>
Tue, 26 Aug 2014 17:12:29 +0000 (13:12 -0400)
get_org_descendants() returns an array ref, not a list, so it doesn't
make sense to assign it to an '@orgs' variable.  Lucky for us, our
where-parser treats this single element list containing the ref in the
same manner as the proper ref itself, but at best, it is still very
confusing to see.

Signed-off-by: Dan Wells <dbw2@calvin.edu>
Signed-off-by: Kathy Lussier <klussier@masslnc.org>
Open-ILS/src/perlmods/lib/OpenILS/Application/Search/Serial.pm

index d445250..0247f4a 100644 (file)
@@ -123,13 +123,13 @@ sub bib_to_svr {
     }
 
     # ou_depth can be undef in get_org_descendants
-    my @orgs = $U->get_org_descendants($ou, $ou_depth);
+    my $orgs = $U->get_org_descendants($ou, $ou_depth);
 
     # TODO: 'deleted' ssub support
     my $sdists = $e->search_serial_distribution([
         {
             "+ssub" => {"record_entry" => $bib},
-            "holding_lib" => { "in" => @orgs }
+            "holding_lib" => { "in" => $orgs }
         },
         {
             "flesh" => 1,
@@ -143,7 +143,7 @@ sub bib_to_svr {
         {
             record => $bib,
             deleted => 'f',
-            "owning_lib" => { "in" => @orgs },
+            "owning_lib" => { "in" => $orgs },
             "+sdist" => {"id" => undef}
         },
         {