src/Http/Curl.php
public function executeRequest($request)
    {
        $body = curl_exec($request);
        $info = curl_getinfo($request);

        curl_close($request);

        $statusCode = $info['http_code'] === 0 ? 500 : $info['http_code'];

        return new Response((string) $body, $statusCode, []);
    }
public function executeRequest($request)
    {
        $body = curl_exec($request);
        $info = curl_getinfo($request);

        curl_close($request);

        $statusCode = $info['http_code'] === 0 ? 500 : $info['http_code'];

        return new Response((string) $body, $statusCode, []);
    }
public function executeRequest ( $ request ) { $ body = curl_exec ( $ request ) ; $ info = curl_getinfo ( $ request ) ; curl_close ( $ request ) ; $ statusCode = $ info [ 'http_code' ] === 0 ? 500 : $ info [ 'http_code' ] ; return new Response ( ( string ) $ body , $ statusCode , [ ] ) ; }
Executes a curl request.

@param  resource $request
@return Response
Executes a curl request .