Fixed PHP8.1 deprecation errors in capitalize modifier

Fixes #789
This commit is contained in:
Simon Wisselink
2022-09-13 12:19:44 +02:00
parent 7494818434
commit d304d349b4
2 changed files with 3 additions and 0 deletions

View File

@@ -22,6 +22,8 @@
*/
function smarty_modifier_capitalize($string, $uc_digits = false, $lc_rest = false)
{
$string = (string) $string;
if (Smarty::$_MBSTRING) {
if ($lc_rest) {
// uppercase (including hyphenated words)