diff --git a/classes/Tools.php b/classes/Tools.php index 8ec0b5ac0..665eece20 100644 --- a/classes/Tools.php +++ b/classes/Tools.php @@ -644,14 +644,14 @@ class ToolsCore { if (is_array($string)) return array_map(array('Tools', 'htmlentitiesUTF8'), $string); - return htmlentities($string, $type, 'utf-8'); + return htmlentities((string)$string, $type, 'utf-8'); } public static function htmlentitiesDecodeUTF8($string) { if (is_array($string)) return array_map(array('Tools', 'htmlentitiesDecodeUTF8'), $string); - return html_entity_decode($string, ENT_QUOTES, 'utf-8'); + return html_entity_decode((string)$string, ENT_QUOTES, 'utf-8'); } public static function safePostVars()