From 33da0c196ab7875f3659c1f35fdfbab0973450a8 Mon Sep 17 00:00:00 2001 From: Hypolite Petovan Date: Mon, 29 May 2023 19:19:41 -0400 Subject: [PATCH] Restore is_string() as a Smarty modifier - Address https://github.com/friendica/friendica/issues/13157#issuecomment-1567336694 --- src/Render/FriendicaSmarty.php | 4 ++++ view/templates/settings/addons/panel.tpl | 2 +- view/theme/frio/templates/settings/addons/panel.tpl | 2 +- 3 files changed, 6 insertions(+), 2 deletions(-) diff --git a/src/Render/FriendicaSmarty.php b/src/Render/FriendicaSmarty.php index 2ace5688a3..1df1ffe4a8 100644 --- a/src/Render/FriendicaSmarty.php +++ b/src/Render/FriendicaSmarty.php @@ -53,6 +53,10 @@ class FriendicaSmarty extends Smarty $this->setConfigDir($work_dir . '/'); $this->setCacheDir($work_dir . '/'); + $this->registerPlugin('modifier', 'is_string', function ($value) { + return is_string($value); + }); + /* * Enable sub-directory splitting for reducing directory descriptor * size. The default behavior is to put all compiled/cached files into diff --git a/view/templates/settings/addons/panel.tpl b/view/templates/settings/addons/panel.tpl index 77c21ab7ff..f401f01231 100644 --- a/view/templates/settings/addons/panel.tpl +++ b/view/templates/settings/addons/panel.tpl @@ -8,7 +8,7 @@ {{$html nofilter}} {{if $submit}}