mirror of
https://github.com/twigphp/Twig.git
synced 2026-10-09 13:25:41 +00:00
Allow null for nl2br, striptags and format filters
Same as https://github.com/twigphp/Twig/pull/3617
This commit is contained in:
@@ -229,7 +229,7 @@ class TwigTestExtension extends AbstractExtension
|
||||
{
|
||||
// not secure if $value contains html tags (not only entities)
|
||||
// don't use
|
||||
return str_replace("\n", "$sep\n", $value);
|
||||
return str_replace("\n", "$sep\n", $value ?? '');
|
||||
}
|
||||
|
||||
public function dynamic_path($element, $item)
|
||||
|
||||
Reference in New Issue
Block a user