Skip to content

Commit 4e631a2

Browse files
authored
Adding null property value check in order Item Mapper (#809)
1 parent 8ed388c commit 4e631a2

File tree

1 file changed

+3
-0
lines changed

1 file changed

+3
-0
lines changed

app/code/Meta/Sales/Model/Mapper/OrderItemMapper.php

+3
Original file line numberDiff line numberDiff line change
@@ -218,6 +218,9 @@ private function getProductOptions(ProductInterface $product, OrderItem $orderIt
218218
$attributeId = (int)$attribute->getAttributeId();
219219
$productAttribute = $attribute->getProductAttribute();
220220
$attributeValue = $product->getData($productAttribute->getAttributeCode());
221+
if ($attributeValue === null) {
222+
continue;
223+
}
221224
$optionId = $productAttribute->getSource()->getOptionId($attributeValue);
222225
$optionText = $productAttribute->getSource()->getOptionText($attributeValue);
223226
$superAttributes[$attributeId] = $optionId;

0 commit comments

Comments
 (0)