From 0328e437f551838bd0c01bef6469e91fbe21bd73 Mon Sep 17 00:00:00 2001 From: Claus Due Date: Wed, 6 Sep 2023 13:45:15 +0200 Subject: [PATCH] [BUGFIX] Cast potentially null subject in v:format.replace --- Classes/ViewHelpers/Format/ReplaceViewHelper.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Classes/ViewHelpers/Format/ReplaceViewHelper.php b/Classes/ViewHelpers/Format/ReplaceViewHelper.php index e1a3c8485..483d17d6e 100644 --- a/Classes/ViewHelpers/Format/ReplaceViewHelper.php +++ b/Classes/ViewHelpers/Format/ReplaceViewHelper.php @@ -41,7 +41,7 @@ public static function renderStatic( \Closure $renderChildrenClosure, RenderingContextInterface $renderingContext ) { - $content = $renderChildrenClosure(); + $content = (string) $renderChildrenClosure(); /** @var string $substring */ $substring = (string) $arguments['substring']; /** @var string $replacement */