Skip to content
This repository has been archived by the owner on Nov 25, 2020. It is now read-only.

Commit

Permalink
Make sure not to load an indexed document if the meta.change event co…
Browse files Browse the repository at this point in the history
…mes from a "delete" operation.
  • Loading branch information
cdujeu committed Dec 30, 2015
1 parent c3f0f34 commit 1654804
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion core/src/plugins/index.lucene/class.AjxpLuceneIndexer.php
Expand Up @@ -422,7 +422,9 @@ public function updateNodeIndexMeta($node)
$id = $this->getIndexedDocumentId($index, $node);
if($id != null) $index->delete($id);
}
$this->createIndexedDocument($node, $index);
if(file_exists($node->getUrl())){
$this->createIndexedDocument($node, $index);
}
$this->logDebug(__FILE__, "Indexation passed ".$node->getUrl());
} catch (Exception $e){
$this->logError(__FILE__, "Lucene indexation failed for ".$node->getUrl()." (".$e->getMessage().")");
Expand Down

0 comments on commit 1654804

Please sign in to comment.