Skip to content

Commit 84ddb3d

Browse files
authored
Merge pull request #6 from antonsacred/deprecations
Make nullable parameter explicit to handle deprecation of php 8.4
2 parents 49014cf + 14daf7d commit 84ddb3d

File tree

7 files changed

+8
-9
lines changed

7 files changed

+8
-9
lines changed

src/Console/BundleInitCommand.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@ class BundleInitCommand extends Command
1818

1919
private KernelInterface $kernel;
2020

21-
public function __construct(KernelInterface $kernel, string $name = null)
21+
public function __construct(KernelInterface $kernel, ?string $name = null)
2222
{
2323
parent::__construct($name);
2424
$this->kernel = $kernel;

src/Console/LogoutCommand.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@ class LogoutCommand extends Command
1818
{
1919
private Nutgram $bot;
2020

21-
public function __construct(Nutgram $bot, string $name = null)
21+
public function __construct(Nutgram $bot, ?string $name = null)
2222
{
2323
parent::__construct($name);
2424
$this->bot = $bot;

src/Console/RegisterCommandsCommand.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@ class RegisterCommandsCommand extends Command
1818

1919
private Nutgram $bot;
2020

21-
public function __construct(Nutgram $bot, string $name = null)
21+
public function __construct(Nutgram $bot, ?string $name = null)
2222
{
2323
parent::__construct($name);
2424
$this->bot = $bot;

src/Console/RunCommand.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@ class RunCommand extends Command
1717

1818
private Nutgram $bot;
1919

20-
public function __construct(Nutgram $bot, string $name = null)
20+
public function __construct(Nutgram $bot, ?string $name = null)
2121
{
2222
parent::__construct($name);
2323
$this->bot = $bot;
@@ -28,4 +28,4 @@ protected function execute(InputInterface $input, OutputInterface $output): int
2828
$this->bot->run();
2929
return Command::SUCCESS;
3030
}
31-
}
31+
}

src/Console/WebhookInfoCommand.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@ class WebhookInfoCommand extends Command
1818

1919
private Nutgram $bot;
2020

21-
public function __construct(Nutgram $bot, string $name = null)
21+
public function __construct(Nutgram $bot, ?string $name = null)
2222
{
2323
parent::__construct($name);
2424
$this->bot = $bot;

src/Console/WebhookRemoveCommand.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@ class WebhookRemoveCommand extends Command
1818
{
1919
private Nutgram $bot;
2020

21-
public function __construct(Nutgram $bot, string $name = null)
21+
public function __construct(Nutgram $bot, ?string $name = null)
2222
{
2323
parent::__construct($name);
2424
$this->bot = $bot;

src/Console/WebhookSetCommand.php

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -19,10 +19,9 @@
1919
class WebhookSetCommand extends Command
2020
{
2121
private Nutgram $bot;
22-
2322
private ParameterBagInterface $parameters;
2423

25-
public function __construct(Nutgram $bot, ParameterBagInterface $parameters, string $name = null)
24+
public function __construct(Nutgram $bot, ParameterBagInterface $parameters, ?string $name = null)
2625
{
2726
parent::__construct($name);
2827
$this->bot = $bot;

0 commit comments

Comments
 (0)