Skip to content

Commit

Permalink
Apply php-cs-fixer fix --rules nullable_type_declaration_for_default_…
Browse files Browse the repository at this point in the history
…null_value
  • Loading branch information
nicolas-grekas committed Jan 23, 2024
1 parent 39bdf55 commit 09e3b2a
Show file tree
Hide file tree
Showing 4 changed files with 4 additions and 4 deletions.
2 changes: 1 addition & 1 deletion Tests/Transport/BeanstalkdTransportTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -50,7 +50,7 @@ public function testReceivesMessages()
$this->assertSame($decodedMessage, $envelopes[0]->getMessage());
}

private function getTransport(SerializerInterface $serializer = null, Connection $connection = null): BeanstalkdTransport
private function getTransport(?SerializerInterface $serializer = null, ?Connection $connection = null): BeanstalkdTransport
{
$serializer = $serializer ?? $this->createMock(SerializerInterface::class);
$connection = $connection ?? $this->createMock(Connection::class);
Expand Down
2 changes: 1 addition & 1 deletion Transport/BeanstalkdReceiver.php
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@ class BeanstalkdReceiver implements ReceiverInterface, MessageCountAwareInterfac
private $connection;
private $serializer;

public function __construct(Connection $connection, SerializerInterface $serializer = null)
public function __construct(Connection $connection, ?SerializerInterface $serializer = null)
{
$this->connection = $connection;
$this->serializer = $serializer ?? new PhpSerializer();
Expand Down
2 changes: 1 addition & 1 deletion Transport/BeanstalkdSender.php
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ class BeanstalkdSender implements SenderInterface
private $connection;
private $serializer;

public function __construct(Connection $connection, SerializerInterface $serializer = null)
public function __construct(Connection $connection, ?SerializerInterface $serializer = null)
{
$this->connection = $connection;
$this->serializer = $serializer ?? new PhpSerializer();
Expand Down
2 changes: 1 addition & 1 deletion Transport/BeanstalkdTransport.php
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@ class BeanstalkdTransport implements TransportInterface, MessageCountAwareInterf
private $receiver;
private $sender;

public function __construct(Connection $connection, SerializerInterface $serializer = null)
public function __construct(Connection $connection, ?SerializerInterface $serializer = null)
{
$this->connection = $connection;
$this->serializer = $serializer ?? new PhpSerializer();
Expand Down

0 comments on commit 09e3b2a

Please sign in to comment.