Skip to content
This repository was archived by the owner on Jan 6, 2024. It is now read-only.

Commit 4b491b7

Browse files
authored
Merge pull request #69 from php-http/clarify-guzzle-argument
explain in phpdoc that guzzle instance must not throw exceptions
2 parents b5fb2a3 + a9551c5 commit 4b491b7

File tree

1 file changed

+5
-0
lines changed

1 file changed

+5
-0
lines changed

src/Client.php

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -25,6 +25,11 @@ final class Client implements HttpClient, HttpAsyncClient
2525
*/
2626
private $client;
2727

28+
/**
29+
* If you pass a Guzzle instance as $client, make sure to configure Guzzle to not
30+
* throw exceptions on HTTP error status codes, or this adapter will violate PSR-18.
31+
* See also self::buildClient at the bottom of this class.
32+
*/
2833
public function __construct(?ClientInterface $client = null)
2934
{
3035
if (!$client) {

0 commit comments

Comments
 (0)