diff options
author | Christian Schneider | 2020-04-30 15:33:18 +0200 |
---|---|---|
committer | Christian Schneider | 2020-04-30 15:33:18 +0200 |
commit | 102778b78bd38b857b2bab7d23d949d7423d55f3 (patch) | |
tree | a6646e389c1a0111887d4fcf28593a80a9862c96 /it_url.class | |
parent | 669c3f2db0566aba235e97ba4b544dd602a72dee (diff) | |
download | itools-102778b78bd38b857b2bab7d23d949d7423d55f3.tar.gz itools-102778b78bd38b857b2bab7d23d949d7423d55f3.tar.bz2 itools-102778b78bd38b857b2bab7d23d949d7423d55f3.zip |
Include both the active and the default language (from user's Accept-Language header) in cache key as they can lead to different output of subrequests
Diffstat (limited to 'it_url.class')
-rw-r--r-- | it_url.class | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/it_url.class b/it_url.class index 2df0aaa..3102913 100644 --- a/it_url.class +++ b/it_url.class @@ -472,7 +472,7 @@ static function get_cache_filename($p) $p = array('url'=>$p); $p['cachedir'] = it_url::get_cache_dir($p); - $filename = $p['cachefilename'] ?: md5(T_lang() . $p['url'] . ($p['headers'] ? serialize($p['headers']) : "") . ($p['data'] ? serialize($p['data']) : "")); + $filename = $p['cachefilename'] ?: md5(T_lang() . T_defaultlang() . $p['url'] . ($p['headers'] ? serialize($p['headers']) : "") . ($p['data'] ? serialize($p['data']) : "")); return $p['cachedir'] . "/" . substr($filename, 0, 2) . "/$filename"; } |