Changeset 3189 for trunk/protemix


Ignore:
Timestamp:
2002-06-25T23:44:46+12:00 (22 years ago)
Author:
sjboddie
Message:

* empty log message *

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/protemix/perllib/plugins/ProtemixPlug.pm

    r3188 r3189  
    119119        my $pdffile = $thisfile;
    120120        $pdffile =~ s/\.html?$/\.pdf/;
    121         die "no PDF file for $thisfile" unless -e $pdffile;
    122         $doc_obj->associate_file($pdffile, "page$count.pdf", undef, $cursection);
    123         $doc_obj->add_utf8_metadata ($cursection, "pdf",  "page$count.pdf");
    124         $doc_obj->add_utf8_metadata ($cursection, "Title", $count);
     121        if (-e $pdffile) {
     122        $doc_obj->associate_file($pdffile, "page$count.pdf", undef, $cursection);
     123        $doc_obj->add_utf8_metadata ($cursection, "pdf",  "page$count.pdf");
     124        $doc_obj->add_utf8_metadata ($cursection, "Title", $count);
     125        } else {
     126        print STDERR "ProtemixPlug: Warning: no pdf file for $thisfile\n";
     127        }
    125128
    126129        # add any section level metadata we have for this page (set from within the meta.xml file)
Note: See TracChangeset for help on using the changeset viewer.