Skip to content

Commit

Permalink
Dont use "soon to be deprecated" functions (#4)
Browse files Browse the repository at this point in the history
  • Loading branch information
Nyholm authored Sep 17, 2020
1 parent 01ef4ad commit 5b361e0
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion src/Client.php
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,7 @@
use GuzzleHttp\ClientInterface;
use GuzzleHttp\HandlerStack;
use GuzzleHttp\Middleware;
use GuzzleHttp\Utils;
use Http\Client\HttpAsyncClient;
use Http\Client\HttpClient;
use Psr\Http\Message\RequestInterface;
Expand Down Expand Up @@ -65,7 +66,7 @@ public function sendAsyncRequest(RequestInterface $request)
*/
private static function buildClient(array $config = []): GuzzleClient
{
$handlerStack = new HandlerStack(\GuzzleHttp\choose_handler());
$handlerStack = new HandlerStack(Utils::chooseHandler());
$handlerStack->push(Middleware::prepareBody(), 'prepare_body');
$config = array_merge(['handler' => $handlerStack], $config);

Expand Down

0 comments on commit 5b361e0

Please sign in to comment.