cacheDir)) ? $this->getFromCache($src) : $this->minify($src); } catch (Exception $e) { if (!$this->keepGoing) throw $e; } return $src; } public function getCacheDifferentiator() { return ''; } protected function getFromCache($src) { $differentiator = $this->getCacheDifferentiator(); $key = \sha1(\serialize([\get_class($this), $differentiator, $src])); $cacheFile = $this->cacheDir . '/minifier.' . $key . '.js'; if (!\file_exists($cacheFile)) \file_put_contents($cacheFile, $this->minify($src)); return \file_get_contents($cacheFile); } }