Skip to content

Commit 27a646c

Browse files
committed
TASK: Remove code that is never used
The case removed with this is never reached, since a removed node will never be handled here. Instead, due to the way removal is handled in the Content Repository and the way we use the signals emitted, a removed node is either handled in removeNode() or not found for an update, since the publication of a removal was already done at this point.
1 parent 1b8d379 commit 27a646c

1 file changed

Lines changed: 0 additions & 8 deletions

File tree

  • Classes/Flowpack/ElasticSearch/ContentRepositoryAdaptor/Indexer

Classes/Flowpack/ElasticSearch/ContentRepositoryAdaptor/Indexer/NodeIndexer.php

Lines changed: 0 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -189,14 +189,6 @@ public function indexNode(NodeInterface $node, $targetWorkspaceName = null)
189189
]));
190190
}
191191

192-
if ($node->isRemoved()) {
193-
// TODO: handle deletion from the fulltext index as well
194-
$mappingType->deleteDocumentById($contextPathHash);
195-
$this->logger->log(sprintf('NodeIndexer: Removed node %s from index (node flagged as removed). ID: %s', $contextPath, $contextPathHash), LOG_DEBUG, null, 'ElasticSearch (CR)');
196-
197-
return;
198-
}
199-
200192
$logger = $this->logger;
201193
$fulltextIndexOfNode = [];
202194
$nodePropertiesToBeStoredInIndex = $this->extractPropertiesAndFulltext($node, $fulltextIndexOfNode, function ($propertyName) use ($logger, $documentIdentifier, $node) {

0 commit comments

Comments
 (0)