diff --git a/src/Tpl.php b/src/Tpl.php index 6b49137..76a57e4 100644 --- a/src/Tpl.php +++ b/src/Tpl.php @@ -272,8 +272,8 @@ class Tpl { } else { $function = new \ReflectionFunction($callable); - $default_smarty_function_name = "smarty_$function"; - $default_smarty_name = $callable; + $default_smarty_function_name = sprintf("smarty_%s", $function->getName()); + $default_smarty_name = $function->getName(); $callable_txt = $callable; $params = $function->getParameters(); }