Changeset 13343


Ignore:
Timestamp:
2006-11-27T10:49:42+13:00 (17 years ago)
Author:
kjdon
Message:

small tidy up changes

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/gsdl/perllib/plugins/OpenDocumentPlug.pm

    r13222 r13343  
    5151           'deft' =>  &get_default_process_exp() }
    5252         ];
     53
    5354my $options = { 'name'     => "OpenDocumentPlug",
    5455        'desc'     => "{OpenDocumentPlug.desc}",
    5556        'abstract' => "no",
    56         'inherits' => "yes" };
     57        'inherits' => "yes",
     58        'args'     => $arguments};
    5759
    5860sub get_default_process_exp { return q^(?i)\.o(?:d|t)(?:t|s|p|g)$^; }
     
    127129    }elsif($element eq 'office:body'){
    128130    #some documents have text in other places that should probably be indexed if we can't find any doc text
    129     if( $self->{'collectedText'} ne "" && $self->{'doc_obj'}->get_text("") eq "") {
     131   
     132    if( defined $self->{'collectedText'} && $self->{'collectedText'} ne "" && $self->{'doc_obj'}->get_text("") eq "") {
    130133        $self->{'doc_obj'}->add_utf8_text("",$self->{'collectedText'});
    131134    }
     
    136139    my $self = shift(@_);
    137140    my ($expat) = @_;
    138    
    139141    if($_ =~ m/\w/i) {
    140142    $self->{'collectedText'} .= "<br/>" if $self->{'collectedText'} ne "";
     
    176178   
    177179    $self->unzip ("\"$file_only\"");
    178    
    179180    foreach my $xmlFile (@OpenDocumentPlug::filesProcess) {
    180         print getcwd();
    181         print $xmlFile;
    182         $self->parse_file($xmlFile);
    183     }
    184        
     181        if (-e $xmlFile) {
     182        $self->parse_file($xmlFile);
     183        }
     184    }
    185185    $self->close_document($filename,$file_only);
    186186   
Note: See TracChangeset for help on using the changeset viewer.