Issues (3)

src/DependencyInjection/Configuration.php (1 issue)

Labels
Severity
1
<?php
2
3
declare(strict_types=1);
4
5
namespace Setono\SyliusLogEntryPlugin\DependencyInjection;
6
7
use Sylius\Bundle\ResourceBundle\SyliusResourceBundle;
8
use Symfony\Component\Config\Definition\Builder\TreeBuilder;
9
use Symfony\Component\Config\Definition\ConfigurationInterface;
10
11
final class Configuration implements ConfigurationInterface
12
{
13
    public function getConfigTreeBuilder(): TreeBuilder
14
    {
15
        $treeBuilder = new TreeBuilder('setono_sylius_log_entry');
16
        $rootNode = $treeBuilder->getRootNode();
17
18
        $rootNode
19
            ->addDefaultsIfNotSet()
0 ignored issues
show
The method addDefaultsIfNotSet() does not exist on Symfony\Component\Config...\Builder\NodeDefinition. It seems like you code against a sub-type of Symfony\Component\Config...\Builder\NodeDefinition such as Symfony\Component\Config...der\ArrayNodeDefinition. ( Ignorable by Annotation )

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

19
            ->/** @scrutinizer ignore-call */ 
20
              addDefaultsIfNotSet()
Loading history...
20
            ->children()
21
                ->scalarNode('driver')->defaultValue(SyliusResourceBundle::DRIVER_DOCTRINE_ORM)->end()
22
            ->end()
23
        ;
24
25
        return $treeBuilder;
26
    }
27
}
28