File tree Expand file tree Collapse file tree 3 files changed +8
-3
lines changed Expand file tree Collapse file tree 3 files changed +8
-3
lines changed Original file line number Diff line number Diff line change 11parameters:
2- level: 1
2+ level: 2
33 paths:
44 - src
Original file line number Diff line number Diff line change 1515use Symfony \Component \HttpFoundation \Cookie ;
1616use Symfony \Component \HttpFoundation \Exception \SessionNotFoundException ;
1717use Symfony \Component \HttpFoundation \ResponseHeaderBag ;
18+ use Symfony \Component \HttpFoundation \Session \FlashBagAwareSessionInterface ;
1819use Symfony \Component \HttpKernel \Event \ResponseEvent ;
1920use Symfony \Component \HttpKernel \KernelEvents ;
2021use Symfony \Component \OptionsResolver \OptionsResolver ;
@@ -56,6 +57,9 @@ public function onKernelResponse(ResponseEvent $event): void
5657 } catch (SessionNotFoundException ) {
5758 return ;
5859 }
60+ if (!($ session instanceof FlashBagAwareSessionInterface)) {
61+ return ;
62+ }
5963
6064 // Flash messages are stored in the session. If there is none, there
6165 // can't be any flash messages in it. $session->getFlashBag() would
Original file line number Diff line number Diff line change @@ -96,8 +96,9 @@ public static function getSubscribedEvents(): array
9696 private function getAttributeTags (Request $ request ): array
9797 {
9898 // Check for _tag request attribute that is set when using Tag attribute
99- /** @var $tagConfigurations Tag[] */
100- if (!$ tagConfigurations = $ request ->attributes ->get ('_tag ' )) {
99+ /** @var Tag[] $tagConfigurations */
100+ $ tagConfigurations = $ request ->attributes ->get ('_tag ' );
101+ if (!$ tagConfigurations ) {
101102 return [];
102103 }
103104
You can’t perform that action at this time.
0 commit comments