original_string: protected function setDefaultData()
      {
          $this->data = array_merge($this->data, $this->getDefaultData());
  
          $this->data['_version'] = gplcart_version();
          $this->data['_user'] = $this->current_user;
          $this->data['_store'] = $this->current_store;
          $this->data['_language'] = $this->current_language;
          $this->data['_maintenance'] = $this->is_maintenance;
          $this->data['_messages'] = $this->session->getMessage();
  
          $default_langcode = $this->language->getDefault();
  
          foreach ($this->language->getList() as $code => $language) {
              if (!empty($language['status']) || $code === $default_langcode) {
                  $this->data['_languages'][$code] = $language;
              }
          }
  
          $this->data['_store_title'] = $this->store->getTranslation('title', $this->langcode);
  
          if (!empty($this->current_store['data']['logo'])) {
              $this->data['_store_logo'] = $this->image($this->current_store['data']['logo']);
          }
  
          if (!empty($this->current_store['data']['favicon'])) {
              $this->data['_store_favicon'] = $this->image($this->current_store['data']['favicon']);
          }
  
          $this->setClasses();
          $this->setDefaultJs();
      }
code: protected function setDefaultData()
      {
          $this->data = array_merge($this->data, $this->getDefaultData());
  
          $this->data['_version'] = gplcart_version();
          $this->data['_user'] = $this->current_user;
          $this->data['_store'] = $this->current_store;
          $this->data['_language'] = $this->current_language;
          $this->data['_maintenance'] = $this->is_maintenance;
          $this->data['_messages'] = $this->session->getMessage();
  
          $default_langcode = $this->language->getDefault();
  
          foreach ($this->language->getList() as $code => $language) {
              if (!empty($language['status']) || $code === $default_langcode) {
                  $this->data['_languages'][$code] = $language;
              }
          }
  
          $this->data['_store_title'] = $this->store->getTranslation('title', $this->langcode);
  
          if (!empty($this->current_store['data']['logo'])) {
              $this->data['_store_logo'] = $this->image($this->current_store['data']['logo']);
          }
  
          if (!empty($this->current_store['data']['favicon'])) {
              $this->data['_store_favicon'] = $this->image($this->current_store['data']['favicon']);
          }
  
          $this->setClasses();
          $this->setDefaultJs();
      }
code_tokens: protected function setDefaultData ( ) { $ this -> data = array_merge ( $ this -> data , $ this -> getDefaultData ( ) ) ; $ this -> data [ '_version' ] = gplcart_version ( ) ; $ this -> data [ '_user' ] = $ this -> current_user ; $ this -> data [ '_store' ] = $ this -> current_store ; $ this -> data [ '_language' ] = $ this -> current_language ; $ this -> data [ '_maintenance' ] = $ this -> is_maintenance ; $ this -> data [ '_messages' ] = $ this -> session -> getMessage ( ) ; $ default_langcode = $ this -> language -> getDefault ( ) ; foreach ( $ this -> language -> getList ( ) as $ code => $ language ) { if ( ! empty ( $ language [ 'status' ] ) || $ code === $ default_langcode ) { $ this -> data [ '_languages' ] [ $ code ] = $ language ; } } $ this -> data [ '_store_title' ] = $ this -> store -> getTranslation ( 'title' , $ this -> langcode ) ; if ( ! empty ( $ this -> current_store [ 'data' ] [ 'logo' ] ) ) { $ this -> data [ '_store_logo' ] = $ this -> image ( $ this -> current_store [ 'data' ] [ 'logo' ] ) ; } if ( ! empty ( $ this -> current_store [ 'data' ] [ 'favicon' ] ) ) { $ this -> data [ '_store_favicon' ] = $ this -> image ( $ this -> current_store [ 'data' ] [ 'favicon' ] ) ; } $ this -> setClasses ( ) ; $ this -> setDefaultJs ( ) ; }
docstring: Sets default template variables
docstring_tokens: Sets default template variables