Skip to content

Commit 1dc6066

Browse files
author
Arif Hoque
committed
default queue job limit issue resolved:
1 parent b788fd4 commit 1dc6066

File tree

1 file changed

+2
-4
lines changed

1 file changed

+2
-4
lines changed

src/QueueWorker.php

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -289,7 +289,7 @@ protected function shouldQuit(): bool
289289
*/
290290
protected function maxJobsReached(): bool
291291
{
292-
return $this->maxJobs !== null && $this->jobsProcessed >= $this->maxJobs;
292+
return !empty($this->maxJobs) && $this->jobsProcessed >= $this->maxJobs;
293293
}
294294

295295
/**
@@ -384,9 +384,7 @@ protected function configureOptions(array $options): void
384384
$this->maxExecutionTime = (int) $options['maxExecutionTime'];
385385
}
386386

387-
if (isset($options['maxJobs'])) {
388-
$this->maxJobs = (int) $options['maxJobs'];
389-
}
387+
$this->maxJobs = $options['maxJobs'] ?? null;
390388
}
391389

392390
/**

0 commit comments

Comments
 (0)