Skip to content

Commit 244a16b

Browse files
committed
Fixed: Removed PHP 8.4 deprecations
1 parent b4afee9 commit 244a16b

File tree

2 files changed

+6
-6
lines changed

2 files changed

+6
-6
lines changed

src/Factories/UploadedFileFactory.php

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -19,10 +19,10 @@ class UploadedFileFactory implements UploadedFileFactoryInterface
1919
*/
2020
public function createUploadedFile(
2121
StreamInterface $stream,
22-
int $size = null,
22+
?int $size = null,
2323
int $error = UPLOAD_ERR_OK,
24-
string $clientFilename = null,
25-
string $clientMediaType = null
24+
?string $clientFilename = null,
25+
?string $clientMediaType = null
2626
): UploadedFileInterface {
2727
if ($size === null) {
2828
$size = $stream->getSize();

src/UploadedFile.php

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -52,10 +52,10 @@ class UploadedFile implements UploadedFileInterface
5252
*/
5353
public function __construct(
5454
$streamOrFile,
55-
private readonly int|null $size,
55+
private readonly ?int $size,
5656
private readonly int $error,
57-
private readonly string|null $clientFilename = null,
58-
private readonly string|null $clientMediaType = null
57+
private readonly ?string $clientFilename = null,
58+
private readonly ?string $clientMediaType = null
5959
) {
6060
if ($error === UPLOAD_ERR_OK) {
6161
if (is_string($streamOrFile)) {

0 commit comments

Comments
 (0)