public function addCSS($file, $minify = true, $addTimestamp = null)
{
$file = (string) $file;
$minify = (bool) $minify;
$addTimestamp = (bool) $addTimestamp;
// get file path
if (mb_substr($file, 0, 4) != 'http') {
$file = Theme::getPath($file);
}
// no minifying when debugging
if ($this->getContainer()->getParameter('kernel.debug')) {
$minify = false;
}
if ($minify) {
$file = $this->minifyCSS($file);
}
$cssFile = array('file' => $file, 'add_timestamp' => $addTimestamp);
// only add when not already in array
if (!isset($this->cssFiles[$file])) {
$this->cssFiles[$file] = $cssFile;
}
}