Skip to content
This repository has been archived by the owner on Aug 17, 2022. It is now read-only.

Commit

Permalink
Merge pull request #28 from loveOSS/improved-unavailable-service-exce…
Browse files Browse the repository at this point in the history
…ption

Improved Unavailable service exception
  • Loading branch information
mickaelandrieu authored Jul 31, 2019
2 parents 36304ab + 2c3aa8b commit ac71241
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion src/Clients/GuzzleClient.php
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,11 @@ public function request(Service $service, Place $place): string

return (string) $client->request($method, $service->getURI(), $clientParameters)->getBody();
} catch (Exception $exception) {
throw new UnavailableService($exception->getMessage());
throw new UnavailableService(
$exception->getMessage(),
(int) $exception->getCode(),
$exception
);
}
}

Expand Down

0 comments on commit ac71241

Please sign in to comment.