Skip to content

Commit 2bc28c5

Browse files
Fix trim(null) deprecation (#36)
Quick fix so it will work with PHP 8+ This is the cause of gantry/gantry5#3130
1 parent 56d0754 commit 2bc28c5

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

Compat/src/Yaml/Inline.php

+1-1
Original file line numberDiff line numberDiff line change
@@ -45,7 +45,7 @@ public static function parse($value, $exceptionOnInvalidType = false, $objectSup
4545
self::$objectSupport = $objectSupport;
4646
self::$objectForMap = $objectForMap;
4747

48-
$value = trim($value);
48+
$value = trim($value ?? '');
4949

5050
if ('' === $value) {
5151
return '';

0 commit comments

Comments
 (0)