In Backend When I try to change theme at that time I got this error

Exception #0 (Exception): Notice: Undefined index: default in /home/cloudpanel/htdocs/project/app/code/Codazon/ThemeOptions/Framework/App/Config/Initial.php on line 72


public function getData($scope)

        list($scopeType, $scopeId) = array_pad(explode('|', $scope), 2, null);
        $this->themeId = $this->scopeConfig->getValue(\Magento\Framework\View\DesignInterface::XML_PATH_THEME_ID,$scopeType,$scopeId);
        $cacheKey = self::CACHE_ID.'|theme|'.$this->themeId;
        $data = $this->cache->load($cacheKey);
        if (!$data) {
            $data = $this->reader->read($this->themeId);
            $this->cache->save(serialize($data), $cacheKey);
        } else {
            $data = unserialize($data);
            $this->_data = $data['data'];
            $this->_metadata = $data['metadata'];
        return $this->_data['default'];

You havent display default anywhere in your code, so remove default from


and set return as only


– Rakesh May 1 at 5:26

this resolved my issue

| improve this answer | |

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.