Skip to content

Commit 2b06a48

Browse files
committed
Update against mainline
1 parent b47cb1f commit 2b06a48

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

app/code/Magento/Catalog/Block/Product/ListProduct.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -84,7 +84,7 @@ public function __construct(
8484
}
8585

8686
/**
87-
* Retrieve loaded category collection
87+
* Retrieve loaded product collection
8888
*
8989
* The goal of this method is to choose whether the existing collection should be returned
9090
* or a new one should be initialized.
@@ -357,7 +357,7 @@ private function initializeProductCollection()
357357
// if the product is associated with any category
358358
if ($categories->count()) {
359359
// show products from this category
360-
$this->setCategoryId(current($categories->getIterator()));
360+
$this->setCategoryId(current($categories->getIterator())->getId());
361361
}
362362
}
363363

0 commit comments

Comments
 (0)