Fix syntax error

This commit is contained in:
nicolaasuni 2022-12-17 10:26:06 +00:00
parent e3d45a6853
commit b133c47e93
2 changed files with 4 additions and 1 deletions

View File

@ -1,3 +1,6 @@
6.6.2 (2022-12-17)
- Ensure pregSplit return type is always array.
6.6.1 (2022-12-12)
- Add PHPStan and fix level 1 errors (#307)

View File

@ -1777,7 +1777,7 @@ class TCPDF_STATIC {
// the bug only happens on PHP 5.2 when using the u modifier
if ((strpos($modifiers, 'u') === FALSE) OR (count(preg_split('//u', "\n\t", -1, PREG_SPLIT_NO_EMPTY)) == 2)) {
$ret = preg_split($pattern.$modifiers, $subject, $limit, $flags);
if $ret === false {
if ($ret === false) {
return array();
}
return $ret;