src/Support/Http/GuzzleClient.php
protected function createResponse(ResponseInterface $response, Request $request)
    {
        $data = json_decode($response->getBody(), true);

        return new Response(
            $response->getHeader('location'),
            (string) $response->getBody(),
            $data ?: [],
            $response->getStatusCode(),
            $response->getHeaders(),
            (string) $response,
            $request
        );
    }
protected function createResponse(ResponseInterface $response, Request $request)
    {
        $data = json_decode($response->getBody(), true);

        return new Response(
            $response->getHeader('location'),
            (string) $response->getBody(),
            $data ?: [],
            $response->getStatusCode(),
            $response->getHeaders(),
            (string) $response,
            $request
        );
    }
@param ResponseInterface $response
@param Request           $request

@return Response