You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{
$headers = array('Content-Type: application/json', 'X-WSSE: ' . $this->getAuthenticationSignature());
$uri = $this->baseUrl . $uri;
try {
$responseJson = $this->client->send($method, $uri, $headers, $body);
} catch (\Exception $e) {
throw new ServerException($e->getMessage());
}
$responseArray = json_decode($responseJson, true);
if ($responseArray === null) {
switch (json_last_error()) {
case JSON_ERROR_DEPTH:
throw new ClientException('JSON response could not be decoded, maximum depth reached.');
default:
throw new ServerException("JSON response could not be decoded:\n" . json_last_error_msg());
}
}
if (is_array($responseArray) === false) {
throw new ServerException("JSON response is not an array:\n" . $responseArray);
}
return new Response($responseArray);
}
in responseJson i got ofter and ofter response
"
503 Service Unavailable
No server is available to handle this request. ";
after json_decode
$responseArray = null and then we throw Exception throw new ServerException("JSON response could not be decoded:\n" . Instead there is no problem with Json encode, there is problem with server and i would rather throw ServerException with payload, methods, uri info :)
The text was updated successfully, but these errors were encountered:
in responseJson i got ofter and ofter response
"
503 Service Unavailable
No server is available to handle this request. ";after json_decode
$responseArray = null and then we throw Exception throw new ServerException("JSON response could not be decoded:\n" . Instead there is no problem with Json encode, there is problem with server and i would rather throw ServerException with payload, methods, uri info :)
The text was updated successfully, but these errors were encountered: