diff --git a/common/modules/product/models/Brand.php b/common/modules/product/models/Brand.php index b11857b..7c6bf04 100644 --- a/common/modules/product/models/Brand.php +++ b/common/modules/product/models/Brand.php @@ -111,8 +111,6 @@ class Brand extends \yii\db\ActiveRecord } public function getName() { - return $this->brandName->value; - $value = $this->getBrandName()->one(); - return empty($value) ? $this->_getValue('name') : $value->value; + return empty($this->brandName) ? null : $this->brandName->value; } } -- libgit2 0.21.4