original_string: public function init()
      {
          $default = $this->config->get('system.languages.default_lang');
          if (isset($default) && $this->validate($default)) {
              $this->default = $default;
          } else {
              $this->default = reset($this->languages);
          }
  
          $this->page_extensions = null;
  
          if (empty($this->languages)) {
              $this->enabled = false;
          }
      }
code: public function init()
      {
          $default = $this->config->get('system.languages.default_lang');
          if (isset($default) && $this->validate($default)) {
              $this->default = $default;
          } else {
              $this->default = reset($this->languages);
          }
  
          $this->page_extensions = null;
  
          if (empty($this->languages)) {
              $this->enabled = false;
          }
      }
code_tokens: public function init ( ) { $ default = $ this -> config -> get ( 'system.languages.default_lang' ) ; if ( isset ( $ default ) && $ this -> validate ( $ default ) ) { $ this -> default = $ default ; } else { $ this -> default = reset ( $ this -> languages ) ; } $ this -> page_extensions = null ; if ( empty ( $ this -> languages ) ) { $ this -> enabled = false ; } }
docstring: Initialize the default and enabled languages
docstring_tokens: Initialize the default and enabled languages