From 9fe01151af380a8ed6a45dec5191df929af155bd Mon Sep 17 00:00:00 2001 From: Nathan Perkins Date: Mon, 16 Jun 2014 10:38:42 -0400 Subject: [PATCH] Add HTTP properties to generic error Allows generic HTTP error to accept more detailed information about the response from the server. --- .../Exceptions/GenericHTTPError.php | 23 +++++++++++++++++-- 1 file changed, 21 insertions(+), 2 deletions(-) diff --git a/src/Mailgun/Connection/Exceptions/GenericHTTPError.php b/src/Mailgun/Connection/Exceptions/GenericHTTPError.php index f7cf8c3..b370649 100644 --- a/src/Mailgun/Connection/Exceptions/GenericHTTPError.php +++ b/src/Mailgun/Connection/Exceptions/GenericHTTPError.php @@ -1,6 +1,25 @@ httpResponseCode = $response_code; + $this->httpResponseBody = $response_body; + } + + public function getHttpResponseCode() { + return $this->httpResponseCode; + } + + public function getHttpResponseBody() { + return $this->httpResponseBody; + } +} -?> \ No newline at end of file +?>