Skip to content

Commit 1810c0b

Browse files
committed
MAGETWO-93258: Optimize retrieving product attributes
1 parent 6aa72c1 commit 1810c0b

File tree

1 file changed

+3
-0
lines changed

1 file changed

+3
-0
lines changed

app/code/Magento/Eav/Model/ResourceModel/UpdateHandler.php

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -123,6 +123,9 @@ public function execute($entityType, $entityData, $arguments = [])
123123
$attributeSetId = isset($entityData[AttributeLoader::ATTRIBUTE_SET_ID])
124124
? $entityData[AttributeLoader::ATTRIBUTE_SET_ID]
125125
: null; // @todo verify is it normal to not have attribute_set_id
126+
if (!isset($entityDataForSnapshot['attribute_set_id'])) {
127+
$entityDataForSnapshot['attribute_set_id'] = $attributeSetId;
128+
}
126129
$snapshot = $this->readSnapshot->execute($entityType, $entityDataForSnapshot);
127130
foreach ($this->getAttributes($entityType, $attributeSetId) as $attribute) {
128131
$code = $attribute->getAttributeCode();

0 commit comments

Comments
 (0)