mirror of
https://github.com/smarty-php/smarty.git
synced 2025-07-31 08:27:14 +02:00
Missed part of commit a3cbdc46
in the merge
This commit is contained in:
@ -14,7 +14,7 @@ class StripTagsModifierCompiler extends Base {
|
||||
|
||||
public function compile($params, \Smarty\Compiler\Template $compiler) {
|
||||
if (!isset($params[ 1 ]) || $params[ 1 ] === true || trim($params[ 1 ], '"') === 'true') {
|
||||
return "preg_replace('!<[^>]*?>!', ' ', {$params[0]} ?: '')";
|
||||
return "preg_replace('!<[^>]*?>!', ' ', (string) {$params[0]})";
|
||||
} else {
|
||||
return 'strip_tags((string) ' . $params[ 0 ] . ')';
|
||||
}
|
||||
|
Reference in New Issue
Block a user