From 782bee0c69c1ea3bf12da028a6ba69c5935a3bbe Mon Sep 17 00:00:00 2001 From: "M. Vugteveen" Date: Tue, 8 Oct 2024 22:24:14 +0200 Subject: [PATCH] Fix laravel/framework#53071 (#53072) --- src/Illuminate/Queue/Console/WorkCommand.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/Illuminate/Queue/Console/WorkCommand.php b/src/Illuminate/Queue/Console/WorkCommand.php index e682dc37b080..69b248d2b129 100644 --- a/src/Illuminate/Queue/Console/WorkCommand.php +++ b/src/Illuminate/Queue/Console/WorkCommand.php @@ -115,7 +115,7 @@ public function handle() // connection being run for the queue operation currently being executed. $queue = $this->getQueue($connection); - if (! $this->option('json') && Terminal::hasSttyAvailable()) { + if (! $this->hasOption('json') && Terminal::hasSttyAvailable()) { $this->components->info( sprintf('Processing jobs from the [%s] %s.', $queue, str('queue')->plural(explode(',', $queue))) ); @@ -201,7 +201,7 @@ protected function listenForEvents() */ protected function writeOutput(Job $job, $status, Throwable $exception = null) { - $this->option('json') + $this->hasOption('json') ? $this->writeOutputAsJson($job, $status, $exception) : $this->writeOutputForCli($job, $status); }