Пример #1
0
 /**
  * @internal Do not use
  *
  * @param bool $force
  */
 public function cacheConfig($force = false)
 {
     if ($this->cacheFile->exists() && $force === false) {
         return;
     }
     $this->cacheFile->dump($this->data);
 }
Пример #2
0
 /**
  * @internal Do not use
  *
  * @param FilesystemInterface $cacheFs
  * @param string              $environment
  * @param bool                $force
  */
 public function cacheConfig(FilesystemInterface $cacheFs, $environment, $force = false)
 {
     $cacheFileName = $environment . '/config-cache.json';
     if ($cacheFs->has($cacheFileName) && $force === false) {
         return;
     }
     $cacheFile = new JsonFile($cacheFs, $cacheFileName);
     $cacheFile->dump($this->data);
 }