- bugfix Smarty failed when compile_id did contain "|"

This commit is contained in:
Uwe Tews
2015-08-06 21:42:20 +02:00
parent c5cf7884d5
commit 643e6784e8
7 changed files with 9 additions and 9 deletions
@@ -83,7 +83,7 @@ abstract class Smarty_CacheResource_Custom extends Smarty_CacheResource
public function populate(Smarty_Template_Cached $cached, Smarty_Internal_Template $_template)
{
$_cache_id = isset($cached->cache_id) ? preg_replace('![^\w\|]+!', '_', $cached->cache_id) : null;
$_compile_id = isset($cached->compile_id) ? preg_replace('![^\w\|]+!', '_', $cached->compile_id) : null;
$_compile_id = isset($cached->compile_id) ? preg_replace('![^\w]+!', '_', $cached->compile_id) : null;
$path = $cached->source->filepath . $_cache_id . $_compile_id;
$cached->filepath = sha1($path);
if ($_template->smarty->cache_locking) {