1
0
mirror of https://github.com/Seldaek/monolog.git synced 2025-08-04 20:27:31 +02:00

Merge pull request #1490 from grubolsch/master

BUGFIX substr() broke when passing a NULL because of strict type
This commit is contained in:
Jordi Boggiano
2020-08-22 12:13:44 +02:00
committed by GitHub

View File

@@ -31,7 +31,7 @@ final class Utils
return mb_strcut($string, $start, $length);
}
return substr($string, $start, $length);
return substr($string, $start, (null === $length) ? strlen($string) : $length);
}
/**