Skip to content

Commit

Permalink
getAttributeCode() on null prevention by moving after AttributeAbstra…
Browse files Browse the repository at this point in the history
…ct check (OpenMage#3344)
  • Loading branch information
discountscott authored Jun 22, 2023
1 parent 9b8eded commit c22f7cc
Showing 1 changed file with 1 addition and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -230,10 +230,10 @@ protected function _loadPrices()
$sortOrder = 1;
foreach ($this->_items as $item) {
$productAttribute = $item->getProductAttribute();
$productAttributeCode = $productAttribute->getAttributeCode();
if (!($productAttribute instanceof Mage_Eav_Model_Entity_Attribute_Abstract)) {
continue;
}
$productAttributeCode = $productAttribute->getAttributeCode();
$options = $productAttribute->getFrontend()->getSelectOptions();

$optionsByValue = [];
Expand Down

0 comments on commit c22f7cc

Please sign in to comment.