Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[5.0] fix issue Queue Worker calling undefined method from the exceptions hand... #6445

Merged
merged 2 commits into from
Nov 20, 2014
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 4 additions & 3 deletions src/Illuminate/Queue/Worker.php
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@
use Illuminate\Contracts\Events\Dispatcher;
use Illuminate\Queue\Failed\FailedJobProviderInterface;
use Illuminate\Contracts\Cache\Repository as CacheContract;
use Illuminate\Contracts\Debug\ExceptionHandler;

class Worker {

Expand Down Expand Up @@ -112,7 +113,7 @@ protected function runNextJobForDaemon($connectionName, $queue, $delay, $sleep,
}
catch (\Exception $e)
{
if ($this->exceptions) $this->exceptions->handleException($e);
if ($this->exceptions) $this->exceptions->report($e);
}
}

Expand Down Expand Up @@ -319,10 +320,10 @@ protected function queueShouldRestart($lastRestart)
/**
* Set the exception handler to use in Daemon mode.
*
* @param \Illuminate\Exception\Handler $handler
* @param \Illuminate\Contracts\Debug\ExceptionHandler $handler
* @return void
*/
public function setDaemonExceptionHandler($handler)
public function setDaemonExceptionHandler(ExceptionHandler $handler)
{
$this->exceptions = $handler;
}
Expand Down