diff --git a/src/BaseClient.php b/src/BaseClient.php index 77f9c0a..8d31353 100644 --- a/src/BaseClient.php +++ b/src/BaseClient.php @@ -315,7 +315,7 @@ protected function sendRequest(string $method, string $path, ?array $query = nul $response = $this->getResponseBody(); // Message will be 'error` array, if absent use status massage $message = empty($response['error']) ? $this->getStatusMessage() : $response['error']; - throw new BEditaClientException($message, $this->getStatusCode()); + throw new BEditaClientException((string)$message, $this->getStatusCode()); } return $this->response;