Smarty v4.5.2 update
This commit is contained in:
@@ -640,17 +640,18 @@ abstract class Smarty_Internal_TemplateCompilerBase
|
|||||||
return $func_name . '(' . $parameter[ 0 ] . ')';
|
return $func_name . '(' . $parameter[ 0 ] . ')';
|
||||||
}
|
}
|
||||||
} else {
|
} else {
|
||||||
$first_param = array_shift($parameter);
|
|
||||||
$modifier = array_merge(array($name), $parameter);
|
if (
|
||||||
// Now, compile the function call as a modifier
|
!$this->smarty->loadPlugin('smarty_modifiercompiler_' . $name)
|
||||||
return $this->compileTag(
|
&& !isset($this->smarty->registered_plugins[Smarty::PLUGIN_MODIFIER][$name])
|
||||||
'private_modifier',
|
&& !in_array($name, ['time', 'join', 'is_array', 'in_array'])
|
||||||
array(),
|
) {
|
||||||
array(
|
trigger_error('Using unregistered function "' . $name . '" in a template is deprecated and will be ' .
|
||||||
'modifierlist' => array($modifier),
|
'removed in a future release. Use Smarty::registerPlugin to explicitly register ' .
|
||||||
'value' => $first_param
|
'a custom modifier.', E_USER_DEPRECATED);
|
||||||
)
|
}
|
||||||
);
|
|
||||||
|
return $name . '(' . implode(',', $parameter) . ')';
|
||||||
}
|
}
|
||||||
} else {
|
} else {
|
||||||
$this->trigger_template_error("unknown function '{$name}'");
|
$this->trigger_template_error("unknown function '{$name}'");
|
||||||
|
|||||||
Reference in New Issue
Block a user