From 6dfd892896fc9f9a5fe302992d866880d5777c57 Mon Sep 17 00:00:00 2001 From: naquad Date: Fri, 23 Feb 2024 13:00:33 +0200 Subject: [PATCH] style fixes --- src/Illuminate/Queue/CallQueuedHandler.php | 5 +++-- src/Illuminate/Queue/UniqueHandler.php | 12 +++++++----- 2 files changed, 10 insertions(+), 7 deletions(-) diff --git a/src/Illuminate/Queue/CallQueuedHandler.php b/src/Illuminate/Queue/CallQueuedHandler.php index 6132858e06c9..a030956c6650 100644 --- a/src/Illuminate/Queue/CallQueuedHandler.php +++ b/src/Illuminate/Queue/CallQueuedHandler.php @@ -58,6 +58,7 @@ public function call(Job $job, array $data) ); } catch (ModelNotFoundException $e) { $this->ensureUniqueJobLockIsReleased($data); + return $this->handleModelNotFound($job, $e); } @@ -84,7 +85,7 @@ public function call(Job $job, array $data) /** * Get the unserialized object from the given payload. * - * @param string $key + * @param string $key * @param array $data * @return mixed */ @@ -128,7 +129,7 @@ protected function getCommand(array $data) /** * Get the unique handler from the given payload. * - * @param array $data + * @param array $data * @return \Illuminate\Queue\UniqueHandler|null */ protected function getUniqueHandler(array $data) diff --git a/src/Illuminate/Queue/UniqueHandler.php b/src/Illuminate/Queue/UniqueHandler.php index 2ce7156677ac..e70896a584a2 100644 --- a/src/Illuminate/Queue/UniqueHandler.php +++ b/src/Illuminate/Queue/UniqueHandler.php @@ -15,7 +15,7 @@ class UniqueHandler { /** - * Original job name + * Original job name. * * @var string */ @@ -37,6 +37,7 @@ class UniqueHandler /** * The container instance. + * * @var \Illuminate\Contracts\Container\Container */ protected $container; @@ -44,7 +45,7 @@ class UniqueHandler /** * Create a new handler instance. * - * @param object $job + * @param object $job */ public function __construct(object $job) { @@ -52,7 +53,7 @@ public function __construct(object $job) if (method_exists($job, 'uniqueId')) { $this->uniqueId = $job->uniqueId(); - } else if (isset($job->uniqueId)) { + } elseif (isset($job->uniqueId)) { $this->uniqueId = $job->uniqueId; } @@ -64,7 +65,7 @@ public function __construct(object $job) /** * Creates a new instance if the job should be unique. * - * @param object $job + * @param object $job * @return \Illuminate\Queue\UniqueHandler|null */ public static function forJob(object $job) @@ -82,12 +83,13 @@ public static function forJob(object $job) /** * Sets the container instance. * - * @param \Illuminate\Contracts\Container\Container $container + * @param \Illuminate\Contracts\Container\Container $container * @return \Illuminate\Queue\UpdateHandler */ public function withContainer(Container $container) { $this->container = $container; + return $this; }