From d5499fc8fcb953251b8477af02d0e113deb56e2e Mon Sep 17 00:00:00 2001 From: Alain Schlesser Date: Mon, 6 Dec 2021 16:08:55 -0500 Subject: [PATCH] Avoid using trim() on null --- src/Mustache/Tokenizer.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/Mustache/Tokenizer.php b/src/Mustache/Tokenizer.php index 6dbe0cd..4a2f06c 100644 --- a/src/Mustache/Tokenizer.php +++ b/src/Mustache/Tokenizer.php @@ -88,11 +88,11 @@ class Mustache_Tokenizer * @throws Mustache_Exception_InvalidArgumentException when $delimiters string is invalid * * @param string $text Mustache template source to tokenize - * @param string $delimiters Optionally, pass initial opening and closing delimiters (default: null) + * @param string $delimiters Optionally, pass initial opening and closing delimiters (default: empty string) * * @return array Set of Mustache tokens */ - public function scan($text, $delimiters = null) + public function scan($text, $delimiters = '') { // Setting mbstring.func_overload makes things *really* slow. // Let's do everyone a favor and scan this string as ASCII instead.