Skip to content

Commit 2d273eb

Browse files
author
Oleksandr Iegorov
committed
MC-42811: Missing Bundled Products on Category Pages
1 parent ed21fb6 commit 2d273eb

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

app/code/Magento/Elasticsearch/Model/Indexer/IndexerHandler.php

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -146,9 +146,9 @@ private function updateCacheContext(array $docs) : void
146146
$categoryIds = [];
147147
foreach ($docs as $document) {
148148
if (is_array($document['category_ids'])) {
149-
array_push($categoryIds, ...$document['category_ids']);
150-
} elseif (!empty($document['category_ids'])) {
151-
array_push($categoryIds, $document['category_ids']);
149+
foreach ($document['category_ids'] as $id) {
150+
$categoryIds[] = $id;
151+
}
152152
}
153153
}
154154
if (!empty($categoryIds)) {

0 commit comments

Comments
 (0)