Skip to content

Commit 3e9172b

Browse files
merge magento/2.3.2-develop into magento-tsg/2.3.2-develop-pr51
2 parents cb53146 + ba04983 commit 3e9172b

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

app/code/Magento/Catalog/Model/Category.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -948,10 +948,10 @@ public function beforeSave()
948948
)
949949
&& !$this->authorization->isAllowed('Magento_Catalog::edit_category_design')
950950
) {
951-
$this->getCustomAttributes();
952951
foreach ($this->_designAttributes as $attributeCode) {
953952
$this->setData($attributeCode, $value = $this->getOrigData($attributeCode));
954-
if (array_key_exists($attributeCode, $this->_data[self::CUSTOM_ATTRIBUTES])) {
953+
if (!empty($this->_data[self::CUSTOM_ATTRIBUTES])
954+
&& array_key_exists($attributeCode, $this->_data[self::CUSTOM_ATTRIBUTES])) {
955955
//In case custom attribute were used to update the entity.
956956
$this->_data[self::CUSTOM_ATTRIBUTES][$attributeCode]->setValue($value);
957957
}

0 commit comments

Comments
 (0)