- improvement $smarty->clearCompiledTemplate() should return on recompiled or uncompiled resources

This commit is contained in:
uwetews
2016-03-11 03:36:43 +01:00
parent af71fda639
commit ff6a8521bb
3 changed files with 3 additions and 2 deletions

View File

@@ -1,6 +1,7 @@
 ===== 3.1.30-dev ===== (xx.xx.xx)  ===== 3.1.30-dev ===== (xx.xx.xx)
11.03.2014 11.03.2014
- optimization of capture and security handling - optimization of capture and security handling
- improvement $smarty->clearCompiledTemplate() should return on recompiled or uncompiled resources
10.03.2014 10.03.2014
- optimization of resource processing - optimization of resource processing

View File

@@ -121,7 +121,7 @@ class Smarty extends Smarty_Internal_TemplateBase
/** /**
* smarty version * smarty version
*/ */
const SMARTY_VERSION = '3.1.30-dev/56'; const SMARTY_VERSION = '3.1.30-dev/57';
/** /**
* define variable scopes * define variable scopes

View File

@@ -48,7 +48,7 @@ class Smarty_Internal_Method_ClearCompiledTemplate
/* @var Smarty_Internal_Template $tpl */ /* @var Smarty_Internal_Template $tpl */
$tpl = new $smarty->template_class($resource_name, $smarty); $tpl = new $smarty->template_class($resource_name, $smarty);
$smarty->caching = $_save_stat; $smarty->caching = $_save_stat;
if ($tpl->source->exists) { if (!$tpl->source->handler->uncompiled && !$tpl->source->handler->recompiled && $tpl->source->exists) {
$_resource_part_1 = basename(str_replace('^', DS, $tpl->compiled->filepath)); $_resource_part_1 = basename(str_replace('^', DS, $tpl->compiled->filepath));
$_resource_part_1_length = strlen($_resource_part_1); $_resource_part_1_length = strlen($_resource_part_1);
} else { } else {