original_string: protected function setDefaultJs()
      {
          foreach ($this->getDefaultData() as $key => $value) {
              $this->setJsSettings(ltrim($key, '_'), $value, 60);
          }
  
          $json = gplcart_json_encode($this->translation->loadJsTranslation());
          $this->setJs("Gplcart.translations=$json;");
      }
code: protected function setDefaultJs()
      {
          foreach ($this->getDefaultData() as $key => $value) {
              $this->setJsSettings(ltrim($key, '_'), $value, 60);
          }
  
          $json = gplcart_json_encode($this->translation->loadJsTranslation());
          $this->setJs("Gplcart.translations=$json;");
      }
code_tokens: protected function setDefaultJs ( ) { foreach ( $ this -> getDefaultData ( ) as $ key => $ value ) { $ this -> setJsSettings ( ltrim ( $ key , '_' ) , $ value , 60 ) ; } $ json = gplcart_json_encode ( $ this -> translation -> loadJsTranslation ( ) ) ; $ this -> setJs ( "Gplcart.translations=$json;" ) ; }
docstring: Adds default JS
docstring_tokens: Adds default JS