summaryrefslogtreecommitdiff
path: root/libs
diff options
context:
space:
mode:
authorGunnar Kreitz <gkreitz@gmail.com>2022-07-14 23:51:26 +0200
committerGitHub <noreply@github.com>2022-07-14 23:51:26 +0200
commit382d66305d7a6fb72ef2452f1863a06eb59b5ab5 (patch)
treecddb7d22f60173c50d28b0f1a8e25e9150fb1b01 /libs
parent44bac8d58c75adf0be771d29afeab6e5923e9856 (diff)
downloadsmarty-382d66305d7a6fb72ef2452f1863a06eb59b5ab5.tar.gz
smarty-382d66305d7a6fb72ef2452f1863a06eb59b5ab5.tar.bz2
smarty-382d66305d7a6fb72ef2452f1863a06eb59b5ab5.zip
Fix PHP 8.1 htmlspecialchars deprecation (#766)
Diffstat (limited to 'libs')
-rw-r--r--libs/sysplugins/smarty_internal_compile_private_print_expression.php2
1 files changed, 1 insertions, 1 deletions
diff --git a/libs/sysplugins/smarty_internal_compile_private_print_expression.php b/libs/sysplugins/smarty_internal_compile_private_print_expression.php
index 23cae8ae..96bd3724 100644
--- a/libs/sysplugins/smarty_internal_compile_private_print_expression.php
+++ b/libs/sysplugins/smarty_internal_compile_private_print_expression.php
@@ -93,7 +93,7 @@ class Smarty_Internal_Compile_Private_Print_Expression extends Smarty_Internal_C
}
// autoescape html
if ($compiler->template->smarty->escape_html) {
- $output = "htmlspecialchars({$output}, ENT_QUOTES, '" . addslashes(Smarty::$_CHARSET) . "')";
+ $output = "htmlspecialchars((string) {$output}, ENT_QUOTES, '" . addslashes(Smarty::$_CHARSET) . "')";
}
// loop over registered filters
if (!empty($compiler->template->smarty->registered_filters[ Smarty::FILTER_VARIABLE ])) {