Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- ################################################################################
- # work horse: index one topic and all attachments
- sub indexTopic {
- my ($this, $web, $topic, $meta, $text) = @_;
- my %outgoingLinks = ();
- my $t0 = [Time::HiRes::gettimeofday] if PROFILE;
- # normalize web name
- $web =~ s/\//\./g;
- if (VERBOSE) {
- $this->log("Indexing topic $web.$topic");
- } else {
- #$this->log(".", 1);
- }
- # new solr document for the current topic
- my $doc = $this->newDocument();
- unless (defined $meta && defined $text) {
- ($meta, $text) = Foswiki::Func::readTopic($web, $topic);
- }
- # PATCH - strip out base64 encoded image data for faster indexing
- $text =~ s/;base64,(.*?)"/"/g;
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement