File tree 1 file changed +5
-5
lines changed
1 file changed +5
-5
lines changed Original file line number Diff line number Diff line change 2
2
3
3
namespace Knp \Bundle \MenuBundle \DependencyInjection ;
4
4
5
+ use Knp \Menu \Factory \ExtensionInterface ;
5
6
use Knp \Menu \ItemInterface ;
6
7
use Knp \Menu \Matcher \Voter \VoterInterface ;
7
8
use Symfony \Component \Config \FileLocator ;
@@ -42,11 +43,10 @@ public function load(array $configs, ContainerBuilder $container): void
42
43
43
44
$ container ->setParameter ('knp_menu.default_renderer ' , $ config ['default_renderer ' ]);
44
45
45
- // Register autoconfiguration rules for Symfony DI 3.3+
46
- if (\method_exists ($ container , 'registerForAutoconfiguration ' )) {
47
- $ container ->registerForAutoconfiguration (VoterInterface::class)
48
- ->addTag ('knp_menu.voter ' );
49
- }
46
+ $ container ->registerForAutoconfiguration (VoterInterface::class)
47
+ ->addTag ('knp_menu.voter ' );
48
+ $ container ->registerForAutoconfiguration (ExtensionInterface::class)
49
+ ->addTag ('knp_menu.factory_extension ' );
50
50
}
51
51
52
52
/**
You can’t perform that action at this time.
0 commit comments