Skip to content

Commit

Permalink
fix webapi
Browse files Browse the repository at this point in the history
  • Loading branch information
engcom-Charlie committed Jun 3, 2020
1 parent a922551 commit beb41d0
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion app/code/Magento/Sales/Model/Order/ItemRepository.php
Original file line number Diff line number Diff line change
Expand Up @@ -185,7 +185,9 @@ private function getItemProductOptions(OrderItemInterface $entity): array
{
$request = $this->getBuyRequest($entity);
$productOptions = $entity->getProductOptions();
$productOptions['info_buyRequest'] = array_merge($productOptions['info_buyRequest'], $request->toArray());
$productOptions['info_buyRequest'] = $productOptions
? array_merge($productOptions['info_buyRequest'], $request->toArray())
: $request->toArray();

return $productOptions;
}
Expand Down

0 comments on commit beb41d0

Please sign in to comment.