Changeset 20801


Ignore:
Timestamp:
2009-10-12T13:06:40+13:00 (13 years ago)
Author:
kjdon
Message:

meta files go into reverse lookups in a different way - store a flag for it to show its a metadata file - if it changes, then the whole folder needs reimporting, so no point storing which ids it belongs to

File:
1 edited

Legend:

Unmodified
Added
Removed
  • gsdl/trunk/perllib/plugouts/BasePlugout.pm

    r20777 r20801  
    688688#       $real_filename =~ s/^$collect_dir_re_safe//;
    689689#       }
    690 
    691         $reverse_lookups->{$real_filename} = 1;
    692 
     690        if (defined $reverse_lookups) {
     691        $reverse_lookups->{$real_filename} = 1;
     692        }
    693693        push(@{$oid_files->{$field}},$full_file);
    694694    }
     
    739739
    740740    $self->archiveinf_files_to_field($doc_obj->get_meta_files(),"meta-file",
    741                      $collect_dir,$oid_files,$reverse_lookups);
     741                     $collect_dir,$oid_files);
    742742
    743743
     
    771771    ## &GDBMUtils::gdbmDatabaseAppend($src_db,$rl,"<oid>$oid\n");   
    772772    $working_info->add_reverseinfo($rl,$oid);
    773     }   
     773    } 
     774
     775    # meta files not set in reverese entry, but need to set the metadata flag
     776    foreach my $meta_file_rec(@{$doc_obj->get_meta_files()}) {
     777    my $full_file = (ref $meta_file_rec eq "ARRAY") ? $meta_file_rec->[0] : $meta_file_rec;
     778    $working_info->set_meta_file_flag($full_file);
     779    }
    774780}
    775781
Note: See TracChangeset for help on using the changeset viewer.