X-Git-Url: http://git.rot13.org/?a=blobdiff_plain;f=authorities%2Fauthorities-list.pl;h=2b15856dcfaf4b371a7c2c732799613f7ff64006;hb=3b608056d9cd86375b51d63a56c054fec1f4a16d;hp=9c472f13f28ecf4081f1a481bf72de5f8af38ce3;hpb=8ad2c7d7acc3cb0033426bd78928214a22ad9dd1;p=koha.git diff --git a/authorities/authorities-list.pl b/authorities/authorities-list.pl old mode 100644 new mode 100755 index 9c472f13f2..2b15856dcf --- a/authorities/authorities-list.pl +++ b/authorities/authorities-list.pl @@ -4,7 +4,7 @@ use warnings; use C4::Context; use C4::AuthoritiesMarc; use utf8; -use open qw( :std :utf8 ); +use open qw[ :std :encoding(utf8) ]; my $dbh=C4::Context->dbh; my $datatypes_query = $dbh->prepare(<{'authid'}; # search for biblios mapped my ($err,$res,$used) = C4::Search::SimpleSearch($query,0,10); + if (defined $err) { + $used = 0; + } if ($marcauthority && $marcauthority->field($authtypes{$authority->{'authtypecode'}}->{'tag'})){ print qq("),$marcauthority->field($authtypes{$authority->{'authtypecode'}}->{"tag"})->as_string(),qq(";),qq($authority->{'authid'};"),$authtypes{$authority->{'authtypecode'}}->{'lib'},qq(";$used\n); }