original_string: public function extractTheme($name, $hash)
      {
          $fileCode = $name . $hash;
          $filePath = $this->getFilePath($fileCode);
  
          if (!Zip::extract($filePath, $this->baseDirectory . '/themes/')) {
              throw new ApplicationException(Lang::get('system::lang.zip.extract_failed', ['file' => $filePath]));
          }
  
          if ($this->themeManager) {
              $this->themeManager->setInstalled($name);
          }
  
          @unlink($filePath);
      }
code: public function extractTheme($name, $hash)
      {
          $fileCode = $name . $hash;
          $filePath = $this->getFilePath($fileCode);
  
          if (!Zip::extract($filePath, $this->baseDirectory . '/themes/')) {
              throw new ApplicationException(Lang::get('system::lang.zip.extract_failed', ['file' => $filePath]));
          }
  
          if ($this->themeManager) {
              $this->themeManager->setInstalled($name);
          }
  
          @unlink($filePath);
      }
code_tokens: public function extractTheme ( $ name , $ hash ) { $ fileCode = $ name . $ hash ; $ filePath = $ this -> getFilePath ( $ fileCode ) ; if ( ! Zip :: extract ( $ filePath , $ this -> baseDirectory . '/themes/' ) ) { throw new ApplicationException ( Lang :: get ( 'system::lang.zip.extract_failed' , [ 'file' => $ filePath ] ) ) ; } if ( $ this -> themeManager ) { $ this -> themeManager -> setInstalled ( $ name ) ; } @ unlink ( $ filePath ) ; }
docstring: Extracts a theme after it has been downloaded.
docstring_tokens: Extracts a theme after it has been downloaded .