Skip to content

Commit 6a1addd

Browse files
committed
fix: collect throwable not only exception
1 parent 541e8ca commit 6a1addd

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

src/Client.php

+2-1
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,7 @@
55
use Socket\Raw\Exception;
66
use Socket\Raw\Factory;
77
use Socket\Raw\Socket;
8+
use Throwable;
89

910
class Client
1011
{
@@ -161,7 +162,7 @@ public function startWorker(string $queue = "default", $jobsToProcess = -1)
161162
$return = false;
162163
try {
163164
$return = call_user_func($this->handlers[$job["Type"]], $job["Payload"], $this->rootValue);
164-
} catch (\Exception $exception) {
165+
} catch (Throwable $exception) {
165166
foreach ($this->exceptionHandlers as $exceptionHandler)
166167
call_user_func($exceptionHandler, $exception);
167168
}

0 commit comments

Comments
 (0)