Bug 8524: Followup FIX an undeclared variable $query
authorJonathan Druart <jonathan.druart@biblibre.com>
Thu, 9 Aug 2012 12:07:35 +0000 (14:07 +0200)
committerPaul Poulain <paul.poulain@biblibre.com>
Fri, 31 Aug 2012 15:42:46 +0000 (17:42 +0200)
Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
cataloguing/value_builder/barcode.pl

index ac10289..5aeae9f 100755 (executable)
@@ -90,7 +90,7 @@ sub plugin_javascript {
     }
     elsif ($autoBarcodeType eq 'EAN13') {
         # not the best, two catalogers could add the same barcode easily this way :/
-        $query = "select max(abs(barcode)) from items";
+        my $query = "select max(abs(barcode)) from items";
         my $sth = $dbh->prepare($query);
         $sth->execute();
         while (my ($last)= $sth->fetchrow_array) {