Skip to content
This repository was archived by the owner on Apr 29, 2019. It is now read-only.

Commit 42b5db5

Browse files
committed
[BUGFIX] Flat Category reindexList of AllChildren if the url_key of the current category has changed
1 parent 86eed24 commit 42b5db5

File tree

1 file changed

+3
-0
lines changed

1 file changed

+3
-0
lines changed

app/code/Magento/Catalog/Model/Category.php

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1095,6 +1095,9 @@ public function reindex()
10951095
$flatIndexer = $this->indexerRegistry->get(Indexer\Category\Flat\State::INDEXER_ID);
10961096
if (!$flatIndexer->isScheduled()) {
10971097
$flatIndexer->reindexRow($this->getId());
1098+
if ($this->dataHasChangedFor('url_key')) {
1099+
$flatIndexer->reindexList(explode(',', $this->getAllChildren()));
1100+
}
10981101
}
10991102
}
11001103
$productIndexer = $this->indexerRegistry->get(Indexer\Category\Product::INDEXER_ID);

0 commit comments

Comments
 (0)