Skip to content

Commit

Permalink
return early if eval call failed (read timeout) (#25020)
Browse files Browse the repository at this point in the history
  • Loading branch information
tillkruss authored and taylorotwell committed Jul 31, 2018
1 parent b35c876 commit ab62f03
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion src/Illuminate/Queue/RedisQueue.php
Original file line number Diff line number Diff line change
Expand Up @@ -162,7 +162,11 @@ public function pop($queue = null)
{
$this->migrate($prefixed = $this->getQueue($queue));

list($job, $reserved) = $this->retrieveNextJob($prefixed);
if (empty($nextJob = $this->retrieveNextJob($prefixed))) {
return;
}

list($job, $reserved) = $nextJob;

if ($reserved) {
return new RedisJob(
Expand Down

0 comments on commit ab62f03

Please sign in to comment.