add Amp\Loop example
[m6w6/seekat] / lib / Exception / RequestException.php
index 7f91535b7d59f3c8cf69af8d26fac31ac4954077..3ef263c00e8d4d72ef700eee5ca5858e15e3dc42 100644 (file)
@@ -2,7 +2,6 @@
 
 namespace seekat\Exception;
 
-use Exception as BaseException;
 use http\ {
        Client\Response,
        Header
@@ -12,7 +11,7 @@ use seekat\Exception;
 /**
  * @code-coverage-ignore
  */
-class RequestException extends BaseException implements Exception
+class RequestException extends \Exception implements Exception
 {
        /**
         * JSON errors
@@ -61,6 +60,13 @@ class RequestException extends BaseException implements Exception
                return $this->errors;
        }
 
+       /**
+        * @return Response
+        */
+       function getResponse() : Response {
+               return $this->response;
+       }
+
        /**
         * Combine any errors into a single string
         * @staticvar array $reasons