Issues (1)

PKEagerResettableServicesExtension.php (1 issue)

Labels
Severity
1
<?php
2
3
declare(strict_types=1);
4
5
namespace PK\EagerResettableServicesBundle\DependencyInjection;
6
7
use Symfony\Component\DependencyInjection\ContainerBuilder;
8
use Symfony\Component\DependencyInjection\Extension\Extension;
9
10
class PKEagerResettableServicesExtension extends Extension
11
{
12
    /**
13
     * {@inheritdoc}
14
     */
15
    public function load(array $configs, ContainerBuilder $container): void
16
    {
17
        $configuration = $this->getConfiguration($configs, $container);
18
        $config = $this->processConfiguration($configuration, $configs);
0 ignored issues
show
It seems like $configuration can also be of type null; however, parameter $configuration of Symfony\Component\Depend...:processConfiguration() does only seem to accept Symfony\Component\Config...\ConfigurationInterface, maybe add an additional type check? ( Ignorable by Annotation )

If this is a false-positive, you can also ignore this issue in your code via the ignore-type  annotation

18
        $config = $this->processConfiguration(/** @scrutinizer ignore-type */ $configuration, $configs);
Loading history...
19
20
        $container->setParameter('pk_eager_resettable_services.services', $config['services']);
21
        $container->setParameter('pk_eager_resettable_services.all_services', $config['all_services']);
22
    }
23
}
24