authorities subdir - Dates.pm integration and warnings fixes.
authorJoe Atzberger <joe.atzberger@liblime.com>
Tue, 4 Dec 2007 23:40:52 +0000 (17:40 -0600)
committerJoshua Ferraro <jmf@liblime.com>
Wed, 5 Dec 2007 00:21:08 +0000 (18:21 -0600)
Signed-off-by: Chris Cormack <crc@liblime.com>
Signed-off-by: Joshua Ferraro <jmf@liblime.com>

authorities/authorities.pl
authorities/detail-biblio-search.pl
authorities/detail.pl

index 7bd6e06..db5498a 100755 (executable)
@@ -224,7 +224,7 @@ sub create_input {
         # opening plugin. Just check wether we are on a developper computer on a production one
         # (the cgidir differs)
         my $cgidir = C4::Context->intranetdir . "/cgi-bin/cataloguing/value_builder";
-        unless ( opendir( DIR, "$cgidir" ) ) {
+        unless (-r $cgidir and -d $cgidir) {
             $cgidir = C4::Context->intranetdir . "/cataloguing/value_builder";
         }
         my $plugin = $cgidir . "/" . $tagslib->{$tag}->{$subfield}->{'value_builder'};
index b421b80..07ba283 100755 (executable)
@@ -77,8 +77,7 @@ my $tag;
 # loop through each tab 0 through 9
 # for (my $tabloop = 0; $tabloop<=10;$tabloop++) {
 # loop through each tag
-       my @fields = $record->fields();
-       my @loop_data =();
+my @fields = $record->fields();
        foreach my $field (@fields) {
                        my @subfields_data;
                # if tag <10, there's no subfield, use the "@" trick
index 9a7a495..2ed7f27 100755 (executable)
@@ -236,7 +236,7 @@ sub create_input {
         # opening plugin. Just check wether we are on a developper computer on a production one
         # (the cgidir differs)
         my $cgidir = C4::Context->intranetdir . "/cgi-bin/cataloguing/value_builder";
-        unless ( opendir( DIR, "$cgidir" ) ) {
+        unless (-r $cgidir and -d $cgidir) {
             $cgidir = C4::Context->intranetdir . "/cataloguing/value_builder";
         }
         my $plugin = $cgidir . "/" . $tagslib->{$tag}->{$subfield}->{'value_builder'};