Skip to content

Commit c4440ba

Browse files
committed
Cleanup dependencies, Rector and ECS
1 parent 038cf9c commit c4440ba

File tree

2 files changed

+4
-7
lines changed

2 files changed

+4
-7
lines changed

phpstan-baseline.neon

-5
Original file line numberDiff line numberDiff line change
@@ -885,11 +885,6 @@ parameters:
885885
count: 1
886886
path: src/Bundle/Resources/config/Algorithms/signature_experimental.php
887887

888-
-
889-
message: "#^Class Jose\\\\Bundle\\\\JoseFramework\\\\Routing\\\\JWKSetLoader has an uninitialized property \\$resolver\\. Give it default value or assign it in the constructor\\.$#"
890-
count: 1
891-
path: src/Bundle/Routing/JWKSetLoader.php
892-
893888
-
894889
message: "#^Method Jose\\\\Bundle\\\\JoseFramework\\\\Serializer\\\\JWEEncoder\\:\\:decode\\(\\) has parameter \\$context with no value type specified in iterable type array\\.$#"
895890
count: 1

src/Bundle/Routing/JWKSetLoader.php

+4-2
Original file line numberDiff line numberDiff line change
@@ -9,12 +9,13 @@
99
use Symfony\Component\Config\Loader\LoaderResolverInterface;
1010
use Symfony\Component\Routing\Route;
1111
use Symfony\Component\Routing\RouteCollection;
12+
use function assert;
1213

13-
final readonly class JWKSetLoader implements LoaderInterface
14+
final class JWKSetLoader implements LoaderInterface
1415
{
1516
private readonly RouteCollection $routes;
1617

17-
private LoaderResolverInterface $resolver;
18+
private null|LoaderResolverInterface $resolver = null;
1819

1920
public function __construct()
2021
{
@@ -45,6 +46,7 @@ public function supports(mixed $resource, string $type = null): bool
4546
#[Override]
4647
public function getResolver(): LoaderResolverInterface
4748
{
49+
assert($this->resolver !== null, 'Resolver is not set.');
4850
return $this->resolver;
4951
}
5052

0 commit comments

Comments
 (0)