Remove different caching headers for development

This has the reason that it's better to add a cache-buster via
requirejs, so only the main.js module must be modified in development
mode and we avoid an ugly bug in recent Chrome versions that prevents
<script> nodes from being correctly loaded in some cases (aborted
requests)

refs #4611 (not really, but kind of)
This commit is contained in:
Jannis Moßhammer 2013-09-11 17:07:33 +02:00
parent f3a47553f8
commit 62e98ccbd7
1 changed files with 1 additions and 6 deletions

View File

@ -117,13 +117,8 @@ class StaticController extends ActionController
}
$response = $this->getResponse();
$response->setHeader('Content-Type', 'text/javascript');
if (!IcingaConfig::app()->global->get('environment') == 'development') {
$this->setCacheHeader(3600);
} else {
$response->setHeader('Pragma', 'no-cache', true);
$response->setHeader('Cache-Control', 'max-age=-3600', true);
$this->setCacheHeader(3600);
}
$response->setHeader(
'Last-Modified',
gmdate(