Skip to content

Commit 51071dc

Browse files
committed
- fix: passing null to string parameter is deprecated
1 parent 12b5581 commit 51071dc

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

functions.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,7 @@ function create_stream(mixed $resource, string $mode = 'r+b'): StreamInterface
2424
{
2525
if (null === $resource || \is_string($resource)) {
2626
$stream = \fopen('php://temp', $mode);
27-
\fwrite($stream, $resource);
27+
\fwrite($stream, $resource ?? '');
2828
\fseek($stream, 0);
2929
return new Stream($stream);
3030
}

0 commit comments

Comments
 (0)