Skip to content

Commit f9e4017

Browse files
committed
psr2 fixes
1 parent 090a977 commit f9e4017

File tree

1 file changed

+8
-5
lines changed

1 file changed

+8
-5
lines changed

src/Provider/AbstractProvider.php

Lines changed: 8 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -99,7 +99,8 @@ abstract class AbstractProvider
9999
/**
100100
* The options given to the Guzzle6 client
101101
* @var array
102-
* @deprecated These are to be removed in the next major release. These options are only used in getHttpClient to keep BC.
102+
* @deprecated These are to be removed in the next major release.
103+
* These options are only used in getHttpClient to keep BC.
103104
*/
104105
private $guzzle6Options = [];
105106

@@ -223,7 +224,7 @@ public function setHttpClient($client)
223224
if ($client instanceof GuzzleClientInterface) {
224225
trigger_error(
225226
sprintf(
226-
'Passing a "%s" to "%s::setHttpClient" is deprecated. Please use a "Http\Client\HttpClient" instead.',
227+
'Passing a "%s" to "%s::setHttpClient" is deprecated. Use a "Http\Client\HttpClient" instead.',
227228
GuzzleClientInterface::class,
228229
static::class
229230
),
@@ -245,8 +246,9 @@ public function setHttpClient($client)
245246
$type = is_object($client) ? get_class($client) : gettype($client);
246247
throw new \RuntimeException(
247248
sprintf(
248-
'First parameter to "%s::setHttpClient" was expected to be a "Http\Client\HttpClient", you provided a "%s"',
249+
'First parameter to "%s::setHttpClient" was expected to be a "%s", you provided a "%s"',
249250
static::class,
251+
HttpClient::class,
250252
$type
251253
)
252254
);
@@ -289,7 +291,8 @@ public function getHttpClient()
289291

290292
if (!class_exists(GuzzleClient::class)) {
291293
throw new \RuntimeException(
292-
'You must install "php-http/guzzle6-adapter" to be able to use "%s::getHttplugClient".', static::class
294+
'You must install "php-http/guzzle6-adapter" to be able to use "%s::getHttplugClient".',
295+
static::class
293296
);
294297
}
295298

@@ -955,7 +958,7 @@ private function getHttpClientFromOptions(array $options, array $collaborators)
955958

956959
if (!class_exists(HttplugGuzzle6::class)) {
957960
throw new \RuntimeException(
958-
'You must install "php-http/guzzle6-adapter" to be able to pass a Guzzle6 client with "httpClient" option.'
961+
'You must install "php-http/guzzle6-adapter" to pass a Guzzle6 client with the "httpClient" option.'
959962
);
960963
}
961964

0 commit comments

Comments
 (0)