Skip to content

Commit

Permalink
Fix generating product URL rewrites for anchor categories
Browse files Browse the repository at this point in the history
(cherry picked from commit 63111ed)
  • Loading branch information
Maksymilian Szydło authored and hostep committed Feb 9, 2020
1 parent 6df825a commit cb685d1
Showing 1 changed file with 1 addition and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -67,7 +67,7 @@ public function generate($storeId, Product $product, ObjectRegistry $productCate
$anchorCategoryIds = $category->getAnchorsAbove();
if ($anchorCategoryIds) {
foreach ($anchorCategoryIds as $anchorCategoryId) {
$anchorCategory = $this->categoryRepository->get($anchorCategoryId);
$anchorCategory = $this->categoryRepository->get($anchorCategoryId, $storeId);
if ((int)$anchorCategory->getParentId() === Category::TREE_ROOT_ID) {
continue;
}
Expand Down

0 comments on commit cb685d1

Please sign in to comment.