diff --git a/Model/ResourceModel/Slider.php b/Model/ResourceModel/Slider.php index 3312b3f..e9566c9 100644 --- a/Model/ResourceModel/Slider.php +++ b/Model/ResourceModel/Slider.php @@ -129,10 +129,8 @@ protected function _beforeSave(AbstractModel $object) $object->setCreatedAt($this->date->date()); } - $location = $object->getLocation(); - if (is_array($location)) { - $object->setLocation(implode(',', $location)); - } + $location = (array)$object->getLocation(); + $object->setLocation(implode(',', $location)); $storeIds = $object->getStoreIds(); if (is_array($storeIds)) {