diff --git a/AsyncClient.php b/AsyncClient.php index 57145fa..ead9c67 100644 --- a/AsyncClient.php +++ b/AsyncClient.php @@ -62,7 +62,7 @@ class AsyncClient extends ClientAbstracts try { $this->generate_client($data, ...$url); } catch (\Throwable $exception) { - Kiri::getDi()->get(Logger::class)->error('rpc', [$exception]); + Kiri::getDi()->get(Logger::class)->error('rpc', [error_trigger_format($exception)]); $this->setStatusCode(-1); $this->setBody(jTraceEx($exception)); } diff --git a/CoroutineClient.php b/CoroutineClient.php index 68ab53e..83402ef 100644 --- a/CoroutineClient.php +++ b/CoroutineClient.php @@ -67,7 +67,7 @@ class CoroutineClient extends ClientAbstracts $this->setBody($this->client->getBody()); $this->setResponseHeader($this->client->headers); } catch (\Throwable $exception) { - Kiri::getDi()->get(Logger::class)->error('rpc', [$exception]); + Kiri::getDi()->get(Logger::class)->error('rpc', [error_trigger_format($exception)]); $this->setStatusCode(-1); $this->setBody(jTraceEx($exception)); }