Total Complexity | 7 |
Total Lines | 44 |
Duplicated Lines | 0 % |
Coverage | 51.85% |
Changes | 0 |
1 | <?php |
||
15 | final class ErrorHandlerInterceptor implements LegacyInterceptor, InterceptorInterface |
||
|
|||
16 | { |
||
17 | 7 | public function __construct( |
|
20 | 7 | } |
|
21 | |||
22 | /** @psalm-suppress ParamNameMismatch */ |
||
23 | 3 | public function process(string $name, string $action, array $parameters, CoreInterface $core): mixed |
|
24 | { |
||
25 | try { |
||
26 | 3 | return $core->callAction($name, $action, $parameters); |
|
27 | 1 | } catch (\Throwable $e) { |
|
28 | 1 | if (!$e instanceof StateException) { |
|
29 | 1 | $this->handler->handle( |
|
30 | 1 | $parameters['driver'], |
|
31 | 1 | $parameters['queue'], |
|
32 | 1 | $name, |
|
33 | 1 | $parameters['payload'], |
|
34 | 1 | $e |
|
35 | 1 | ); |
|
36 | } |
||
37 | |||
38 | 1 | throw $e; |
|
39 | } |
||
40 | } |
||
41 | |||
42 | public function intercept(CallContextInterface $context, HandlerInterface $handler): mixed |
||
59 | } |
||
60 | } |
||
62 |
This interface has been deprecated. The supplier of the interface has supplied an explanatory message.
The explanatory message should give you some clue as to whether and when the interface will be removed and what other interface to use instead.