diff --git a/build/kint.phar b/build/kint.phar index b261192ff..752f15a92 100644 Binary files a/build/kint.phar and b/build/kint.phar differ diff --git a/src/Utils.php b/src/Utils.php index 3f3832f35..0fcdc4788 100644 --- a/src/Utils.php +++ b/src/Utils.php @@ -309,7 +309,7 @@ public static function isValidPhpNamespace(string $ns): bool */ public static function errorSanitizeString(string $input): string { - if (KINT_PHP82) { + if (KINT_PHP82 || '' === $input) { return $input; } diff --git a/tests/UtilsTest.php b/tests/UtilsTest.php index ada3202f2..532e01bb5 100644 --- a/tests/UtilsTest.php +++ b/tests/UtilsTest.php @@ -615,6 +615,8 @@ public function testErrorSanitizeString() } else { $this->assertSame('Hello', Utils::errorSanitizeString($input)); } + + $this->assertSame('', Utils::errorSanitizeString('')); } public function blobProvider()