Skip to content

Commit fadf3e7

Browse files
committed
fix on kernel view event
1 parent 7ae49c5 commit fadf3e7

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

src/Listeners/KernelEventsSubscriber.php

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -310,8 +310,10 @@ public function onKernelView(ViewEvent $event): void
310310

311311
$controllerLabel = $event->getRequest()->attributes->get('_controller');
312312

313-
if ($controllerLabel) {
313+
if (is_string($controllerLabel)) {
314314
$this->endSegment($controllerLabel);
315+
} elseif (is_array($controllerLabel)) {
316+
$this->endSegment(implode('::', $controllerLabel));
315317
}
316318

317319
$this->startSegment(self::SEGMENT_TYPE_TEMPLATE, KernelEvents::VIEW);

0 commit comments

Comments
 (0)