Skip to content

Commit 4e78c6e

Browse files
authored
Fix missing profile option for console commands
Fixes symfony/symfony#52433
1 parent 79174a4 commit 4e78c6e

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

EventListener/ConsoleProfilerListener.php

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -59,7 +59,8 @@ public static function getSubscribedEvents(): array
5959

6060
public function initialize(ConsoleCommandEvent $event): void
6161
{
62-
if (!$event->getInput()->getOption('profile')) {
62+
$input = $event->getInput();
63+
if (!$input->hasOption('profile') || !$input->getOption('profile')) {
6364
$this->profiler->disable();
6465

6566
return;

0 commit comments

Comments
 (0)