Skip to content

Commit

Permalink
[PHP 8.4] Fixes for implicit nullability deprecation
Browse files Browse the repository at this point in the history
Fixes all issues that emit deprecation notices on PHP 8.4 for implicit nullable parameter type declarations.

See:
 - [RFC](https://wiki.php.net/rfc/deprecate-implicitly-nullable-types)
 - [PHP 8.4: Implicitly nullable parameter declarations deprecated](https://php.watch/versions/8.4/implicitly-marking-parameter-type-nullable-deprecated)
  • Loading branch information
Ayesh committed Mar 15, 2024
1 parent 809474e commit 6a5be0e
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
4 changes: 2 additions & 2 deletions AwsS3V3Adapter.php
Original file line number Diff line number Diff line change
Expand Up @@ -99,8 +99,8 @@ public function __construct(
private S3ClientInterface $client,
private string $bucket,
string $prefix = '',
VisibilityConverter $visibility = null,
MimeTypeDetector $mimeTypeDetector = null,
?VisibilityConverter $visibility = null,
?MimeTypeDetector $mimeTypeDetector = null,
private array $options = [],
private bool $streamReads = true,
private array $forwardedOptions = self::AVAILABLE_OPTIONS,
Expand Down
2 changes: 1 addition & 1 deletion S3ClientStub.php
Original file line number Diff line number Diff line change
Expand Up @@ -69,7 +69,7 @@ public function failOnNextCopy(): void
$this->throwExceptionWhenExecutingCommand('CopyObject');
}

public function throwExceptionWhenExecutingCommand(string $commandName, S3Exception $exception = null): void
public function throwExceptionWhenExecutingCommand(string $commandName, ?S3Exception $exception = null): void
{
$this->stagedExceptions[$commandName] = $exception ?? new S3Exception($commandName, new Command($commandName));
}
Expand Down

0 comments on commit 6a5be0e

Please sign in to comment.