Skip to content
This repository has been archived by the owner on Nov 3, 2023. It is now read-only.

Commit

Permalink
Fix the cache key usage (see #8695).
Browse files Browse the repository at this point in the history
  • Loading branch information
fritzmg authored and leofeyer committed Apr 20, 2017
1 parent ae7256f commit 6289a8c
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/Resources/contao/classes/FrontendTemplate.php
Expand Up @@ -213,7 +213,7 @@ protected function addToCache()
// If the request string is empty, use a special cache tag which considers the page language
if (\Environment::get('request') == '' || \Environment::get('request') == 'index.php')
{
$strCacheKey = \Environment::get('host') . '/empty.' . $objPage->language;
$strCacheKey = ($objPage->domain ?: '*') . '/empty.' . $objPage->language;
}
else
{
Expand Down Expand Up @@ -250,7 +250,7 @@ protected function addToCache()
// Add the cache file header
$strHeader = sprintf
(
"<?php /* %s */ \$expire = %d; \$content = %s; \$type = %s; \$files = %s; \$assets = %s; ?>\n",
"<?php\n\n// %s\n\$expire = %d;\n\$content = %s;\n\$type = %s;\n\$files = %s;\n\$assets = %s;\n\n?>\n",
$strCacheKey,
(int) $intCache,
var_export($this->strContentType, true),
Expand Down

0 comments on commit 6289a8c

Please sign in to comment.