Skip to content

Commit 0e31742

Browse files
committed
MAGETWO-49721: Revert backward incompatible changes related to product modules
- Fixed incorrect usage of metadataPool entity
1 parent 06a85ef commit 0e31742

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

app/code/Magento/ConfigurableProduct/Model/Product/Type/Configurable.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -376,7 +376,7 @@ public function getConfigurableAttributes($product)
376376
['group' => 'CONFIGURABLE', 'method' => __METHOD__]
377377
);
378378
if (!$product->hasData($this->_configurableAttributes)) {
379-
$metadata = $this->metadataPool->getMetadata(ProductInterface::class);
379+
$metadata = $this->getMetadataPool()->getMetadata(ProductInterface::class);
380380
$cacheId = __CLASS__ . $product->getData($metadata->getLinkField()) . '_' . $product->getStoreId();
381381
$configurableAttributes = $this->cache->load($cacheId);
382382
$configurableAttributes = $this->hasCacheData($configurableAttributes);
@@ -615,7 +615,7 @@ public function beforeSave($product)
615615
public function save($product)
616616
{
617617
parent::save($product);
618-
$metadata = $this->metadataPool->getMetadata(ProductInterface::class);
618+
$metadata = $this->getMetadataPool()->getMetadata(ProductInterface::class);
619619
$cacheId = __CLASS__ . $product->getData($metadata->getLinkField()) . '_' . $product->getStoreId();
620620
$this->cache->remove($cacheId);
621621

0 commit comments

Comments
 (0)