File tree Expand file tree Collapse file tree 1 file changed +7
-0
lines changed Expand file tree Collapse file tree 1 file changed +7
-0
lines changed Original file line number Diff line number Diff line change @@ -6,6 +6,13 @@ The ``ErrorPlugin`` transforms responses with HTTP error status codes into excep
6
6
* 400-499 status code are transformed into ``Http\Client\Common\Exception\ClientErrorException ``;
7
7
* 500-599 status code are transformed into ``Http\Client\Common\Exception\ServerErrorException ``
8
8
9
+ .. warning ::
10
+
11
+ Throwing an exception on a valid response violates the PSR-18 specification.
12
+ This plugin is provided as a convenience when writing a small application.
13
+ When providing a client to a third party library, this plugin must not be
14
+ included, or the third party library will have problems with error handling.
15
+
9
16
Both exceptions extend the ``Http\Client\Exception\HttpException `` class, so you can fetch the request
10
17
and the response coming from them::
11
18
You can’t perform that action at this time.
0 commit comments