Skip to content

Commit 268992a

Browse files
author
Yushkin, Dmytro
committed
MAGETWO-50198: [GITHUB] Options for Configurable product are merged in one product if Reorder #3654
- Added annotation
1 parent ba9f4b8 commit 268992a

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

app/code/Magento/Checkout/Model/Cart.php

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -257,6 +257,10 @@ public function addOrderItem($orderItem, $qtyFlag = null)
257257
if ($orderItem->getParentItem() === null) {
258258
$storeId = $this->_storeManager->getStore()->getId();
259259
try {
260+
/**
261+
* We need to reload product in this place, because products
262+
* with the same id may have different sets of order attributes.
263+
*/
260264
$product = $this->productRepository->getById($orderItem->getProductId(), false, $storeId, true);
261265
} catch (NoSuchEntityException $e) {
262266
return $this;

0 commit comments

Comments
 (0)