Skip to content

Commit

Permalink
fix
Browse files Browse the repository at this point in the history
  • Loading branch information
wisskid committed Apr 5, 2024
1 parent 6a1f56d commit cabc862
Show file tree
Hide file tree
Showing 2 changed files with 1 addition and 8 deletions.
2 changes: 1 addition & 1 deletion libs/sysplugins/smarty_internal_templatecompilerbase.php
Expand Up @@ -643,7 +643,7 @@ public function compilePHPFunctionCall($name, $parameter)

if (
!$this->smarty->loadPlugin('smarty_modifiercompiler_' . $name)
&& !$this->getPlugin($name, Smarty::PLUGIN_MODIFIER)
&& !isset($this->smarty->registered_plugins[Smarty::PLUGIN_MODIFIER][$name])
&& !in_array($name, ['time', 'join', 'is_array', 'in_array'])
) {
trigger_error('Using unregistered function "' . $name . '" in a template is deprecated and will be ' .
Expand Down
Expand Up @@ -25,11 +25,6 @@ public function testReset()
public function testResetAsModifier()
{
$smarty = new Smarty();

// $previousErrorReporting = $smarty->error_reporting;
// $smarty->setErrorReporting($previousErrorReporting | E_USER_DEPRECATED);
// $smarty->registerPlugin('modifier', 'reset', 'reset');
// $this->expectDeprecation();
try {
$templateStr = "string:{\$ar|reset}";
$smarty->assign('ar', [1,2,3]);
Expand All @@ -39,8 +34,6 @@ public function testResetAsModifier()
);
} catch (Exception $e) {
}

// $smarty->setErrorReporting($previousErrorReporting);
}

/**
Expand Down

0 comments on commit cabc862

Please sign in to comment.