use Memoize because Memcache::Memoize is slow for me
[koha.git] / C4 / Koha.pm
index 47cd183..06b2ec5 100644 (file)
@@ -1051,7 +1051,7 @@ sub GetAuthorisedValueCategories {
     my $sth = $dbh->prepare("SELECT DISTINCT category FROM authorised_values ORDER BY category");
     $sth->execute;
     my @results;
-    while (my $category = $sth->fetchrow_array) {
+    while (defined (my $category  = $sth->fetchrow_array) ) {
         push @results, $category;
     }
     return \@results;