diff --git a/classes/Attribute.php b/classes/Attribute.php index c27e409b3..93391bc6c 100644 --- a/classes/Attribute.php +++ b/classes/Attribute.php @@ -71,7 +71,7 @@ class AttributeCore extends ObjectModel public function delete() { - if (!$this->hasMultishopEntries()) + if (!$this->hasMultishopEntries() || Shop::getContext() == Shop::CONTEXT_ALL) { $result = Db::getInstance()->executeS('SELECT id_product_attribute FROM '._DB_PREFIX_.'product_attribute_combination WHERE id_attribute = '.(int)$this->id); foreach ($result as $row) @@ -343,4 +343,4 @@ class AttributeCore extends ObjectModel return (is_numeric($position)) ? $position : -1; } -} +} \ No newline at end of file diff --git a/classes/AttributeGroup.php b/classes/AttributeGroup.php index 665ec87f2..15f72122a 100644 --- a/classes/AttributeGroup.php +++ b/classes/AttributeGroup.php @@ -119,7 +119,7 @@ class AttributeGroupCore extends ObjectModel public function delete() { - if (!$this->hasMultishopEntries()) + if (!$this->hasMultishopEntries() || Shop::getContext() == Shop::CONTEXT_ALL) { /* Select children in order to find linked combinations */ $attribute_ids = Db::getInstance()->executeS('