mirror of
https://github.com/smarty-php/smarty.git
synced 2025-08-04 10:24:26 +02:00
fix typo, fix write_cache_paths logic
This commit is contained in:
@@ -18,7 +18,7 @@
|
||||
function smarty_core_assemble_auto_filename($params, &$smarty)
|
||||
{
|
||||
|
||||
$_compile_dir_sep = $this->use_sub_dirs ? DIRECTORY_SEPARATOR : '^';
|
||||
$_compile_dir_sep = $smarty->use_sub_dirs ? DIRECTORY_SEPARATOR : '^';
|
||||
|
||||
if(@is_dir($params['auto_base'])) {
|
||||
$_return = $params['auto_base'] . DIRECTORY_SEPARATOR;
|
||||
|
@@ -14,6 +14,9 @@
|
||||
|
||||
function smarty_core_write_cache_paths_file($params, &$smarty)
|
||||
{
|
||||
if (!isset($smarty->_cache_paths_file)) {
|
||||
return false;
|
||||
}
|
||||
$_compiled_content = function_exists('var_export') ? var_export($smarty->_cache_paths, true) : "unserialize('" . serialize($smarty->_cache_paths) . "')";
|
||||
$_compiled_content = '<?php $this->_cache_paths = ' . $_compiled_content . '; ?>';
|
||||
$_params = array('compile_path' => $smarty->_cache_paths_file, 'compiled_content' => $_compiled_content, 'resource_timestamp' => time());
|
||||
|
Reference in New Issue
Block a user