Skip to content

Commit 21f644a

Browse files
Merge branch '6.4' into 7.0
* 6.4: Fix implicitly-required parameters minor #53524 [Messenger] [AmazonSqs] Allow `async-aws/sqs` version 2 (smoench) Fix bad merge List CS fix in .git-blame-ignore-revs Fix implicitly-required parameters List CS fix in .git-blame-ignore-revs Apply php-cs-fixer fix --rules nullable_type_declaration_for_default_null_value [Messenger][AmazonSqs] Allow async-aws/sqs version 2
2 parents a60f783 + c78f26c commit 21f644a

File tree

10 files changed

+12
-12
lines changed

10 files changed

+12
-12
lines changed

CacheWarmer/ExpressionCacheWarmer.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -34,7 +34,7 @@ public function isOptional(): bool
3434
return true;
3535
}
3636

37-
public function warmUp(string $cacheDir, string $buildDir = null): array
37+
public function warmUp(string $cacheDir, ?string $buildDir = null): array
3838
{
3939
foreach ($this->expressions as $expression) {
4040
$this->expressionLanguage->parse($expression, ['token', 'user', 'object', 'subject', 'role_names', 'request', 'trust_resolver']);

DataCollector/SecurityDataCollector.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -44,7 +44,7 @@ class SecurityDataCollector extends DataCollector implements LateDataCollectorIn
4444
private ?TraceableFirewallListener $firewall;
4545
private bool $hasVarDumper;
4646

47-
public function __construct(TokenStorageInterface $tokenStorage = null, RoleHierarchyInterface $roleHierarchy = null, LogoutUrlGenerator $logoutUrlGenerator = null, AccessDecisionManagerInterface $accessDecisionManager = null, FirewallMapInterface $firewallMap = null, TraceableFirewallListener $firewall = null)
47+
public function __construct(?TokenStorageInterface $tokenStorage = null, ?RoleHierarchyInterface $roleHierarchy = null, ?LogoutUrlGenerator $logoutUrlGenerator = null, ?AccessDecisionManagerInterface $accessDecisionManager = null, ?FirewallMapInterface $firewallMap = null, ?TraceableFirewallListener $firewall = null)
4848
{
4949
$this->tokenStorage = $tokenStorage;
5050
$this->roleHierarchy = $roleHierarchy;
@@ -55,7 +55,7 @@ public function __construct(TokenStorageInterface $tokenStorage = null, RoleHier
5555
$this->hasVarDumper = class_exists(ClassStub::class);
5656
}
5757

58-
public function collect(Request $request, Response $response, \Throwable $exception = null): void
58+
public function collect(Request $request, Response $response, ?\Throwable $exception = null): void
5959
{
6060
if (null === $this->tokenStorage) {
6161
$this->data = [

DependencyInjection/SecurityExtension.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -917,7 +917,7 @@ private function createExpression(ContainerBuilder $container, string $expressio
917917
return $this->expressions[$id] = new Reference($id);
918918
}
919919

920-
private function createRequestMatcher(ContainerBuilder $container, string $path = null, string $host = null, int $port = null, array $methods = [], array $ips = null, array $attributes = []): Reference
920+
private function createRequestMatcher(ContainerBuilder $container, ?string $path = null, ?string $host = null, ?int $port = null, array $methods = [], ?array $ips = null, array $attributes = []): Reference
921921
{
922922
if ($methods) {
923923
$methods = array_map('strtoupper', $methods);

LoginLink/FirewallAwareLoginLinkHandler.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -38,7 +38,7 @@ public function __construct(FirewallMap $firewallMap, ContainerInterface $loginL
3838
$this->requestStack = $requestStack;
3939
}
4040

41-
public function createLoginLink(UserInterface $user, Request $request = null, int $lifetime = null): LoginLinkDetails
41+
public function createLoginLink(UserInterface $user, ?Request $request = null, ?int $lifetime = null): LoginLinkDetails
4242
{
4343
return $this->getForFirewall()->createLoginLink($user, $request, $lifetime);
4444
}

Security.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -81,7 +81,7 @@ public function getFirewallConfig(Request $request): ?FirewallConfig
8181
*
8282
* @return Response|null The authenticator success response if any
8383
*/
84-
public function login(UserInterface $user, string $authenticatorName = null, string $firewallName = null, array $badges = []): ?Response
84+
public function login(UserInterface $user, ?string $authenticatorName = null, ?string $firewallName = null, array $badges = []): ?Response
8585
{
8686
$request = $this->container->get('request_stack')->getCurrentRequest();
8787
if (null === $request) {

Security/FirewallContext.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -30,7 +30,7 @@ class FirewallContext
3030
/**
3131
* @param iterable<mixed, callable> $listeners
3232
*/
33-
public function __construct(iterable $listeners, ExceptionListener $exceptionListener = null, LogoutListener $logoutListener = null, FirewallConfig $config = null)
33+
public function __construct(iterable $listeners, ?ExceptionListener $exceptionListener = null, ?LogoutListener $logoutListener = null, ?FirewallConfig $config = null)
3434
{
3535
$this->listeners = $listeners;
3636
$this->exceptionListener = $exceptionListener;

Tests/DataCollector/SecurityDataCollectorTest.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -227,7 +227,7 @@ public function testCollectCollectsDecisionLogWhenStrategyIsAffirmative()
227227
$voter2 = new DummyVoter();
228228

229229
$decoratedVoter1 = new TraceableVoter($voter1, new class() implements EventDispatcherInterface {
230-
public function dispatch(object $event, string $eventName = null): object
230+
public function dispatch(object $event, ?string $eventName = null): object
231231
{
232232
return new \stdClass();
233233
}
@@ -302,7 +302,7 @@ public function testCollectCollectsDecisionLogWhenStrategyIsUnanimous()
302302
$voter2 = new DummyVoter();
303303

304304
$decoratedVoter1 = new TraceableVoter($voter1, new class() implements EventDispatcherInterface {
305-
public function dispatch(object $event, string $eventName = null): object
305+
public function dispatch(object $event, ?string $eventName = null): object
306306
{
307307
return new \stdClass();
308308
}

Tests/DependencyInjection/Compiler/RegisterEntryPointsPassTest.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -93,7 +93,7 @@ public function onAuthenticationFailure(Request $request, AuthenticationExceptio
9393
], JsonResponse::HTTP_FORBIDDEN);
9494
}
9595

96-
public function start(Request $request, AuthenticationException $authException = null): Response
96+
public function start(Request $request, ?AuthenticationException $authException = null): Response
9797
{
9898
}
9999
}

Tests/Functional/Bundle/FirewallEntryPointBundle/Security/EntryPointStub.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,7 @@ class EntryPointStub implements AuthenticationEntryPointInterface
2020
{
2121
public const RESPONSE_TEXT = '2be8e651259189d841a19eecdf37e771e2431741';
2222

23-
public function start(Request $request, AuthenticationException $authException = null): Response
23+
public function start(Request $request, ?AuthenticationException $authException = null): Response
2424
{
2525
return new Response(self::RESPONSE_TEXT);
2626
}

Tests/Functional/Bundle/FormLoginBundle/Controller/LoginController.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -29,7 +29,7 @@ public function __construct(ContainerInterface $container)
2929
$this->container = $container;
3030
}
3131

32-
public function loginAction(Request $request, UserInterface $user = null)
32+
public function loginAction(Request $request, ?UserInterface $user = null)
3333
{
3434
// get the login error if there is one
3535
if ($request->attributes->has(SecurityRequestAttributes::AUTHENTICATION_ERROR)) {

0 commit comments

Comments
 (0)