File tree Expand file tree Collapse file tree 3 files changed +8
-2
lines changed
Expand file tree Collapse file tree 3 files changed +8
-2
lines changed Original file line number Diff line number Diff line change 4242 "menatwork/contao-multicolumnwizard-bundle" : " ^3.5" ,
4343 "symfony/config" : " ^5.4 || ^6.4" ,
4444 "symfony/dependency-injection" : " ^5.4 || ^6.4" ,
45- "symfony/http-kernel" : " ^5.4 || ^6.4"
45+ "symfony/http-kernel" : " ^5.4 || ^6.4" ,
46+ "symfony/security-bundle" : " ^5.4 || ^6.4" ,
47+ "symfony/security-core" : " ^5.4 || ^6.4"
4648 },
4749 "require-dev" : {
4850 "contao/manager-plugin" : " ^2.1" ,
Original file line number Diff line number Diff line change 1111use Doctrine \DBAL \Connection ;
1212use Hofff \Contao \Content \Renderer \ArticleRenderer ;
1313use Hofff \Contao \Navigation \Event \ItemEvent ;
14+ use Symfony \Bundle \SecurityBundle \Security ;
15+ use Symfony \Component \Security \Core \Security as CoreSecurity ;
1416
1517use function array_map ;
1618use function array_unique ;
@@ -28,6 +30,7 @@ public function __construct(
2830 private Connection $ connection ,
2931 private ContaoFramework $ contaoFramework ,
3032 private TokenChecker $ tokenChecker ,
33+ private Security |CoreSecurity $ security ,
3134 ) {
3235 }
3336
@@ -56,7 +59,7 @@ public function __invoke(ItemEvent $event): void
5659 continue ;
5760 }
5861
59- $ renderer = new ArticleRenderer ($ this ->tokenChecker );
62+ $ renderer = new ArticleRenderer ($ this ->tokenChecker , $ this -> security );
6063 $ renderer ->setArticle ($ models [$ article ['article ' ]]);
6164 $ renderer ->setRenderContainer ((bool ) $ article ['container ' ]);
6265 $ renderer ->setExcludeFromSearch ((bool ) $ article ['nosearch ' ]);
Original file line number Diff line number Diff line change 1111 <argument type =" service" id =" database_connection" />
1212 <argument type =" service" id =" contao.framework" />
1313 <argument type =" service" id =" contao.security.token_checker" />
14+ <argument type =" service" id =" security.helper" />
1415 <tag name =" kernel.event_listener" event =" Hofff\Contao\Navigation\Event\ItemEvent" />
1516 </service >
1617
You can’t perform that action at this time.
0 commit comments