It seems like the GitHub access token used for retrieving details about this repository from
GitHub became invalid. This might prevent certain types of inspections from being run (in
particular,
everything related to pull requests).
Please ask an admin of your repository to re-new the access token on this website.
abstract class AbstractHttpProvider extends AbstractProvider
18
{
19
/**
20
*
21
* @var Client
22
*/
23
private $client;
24
25
/**
26
*
27
* @param Client $client
28
*/
29
3
public function __construct(Client $client)
30
{
31
3
$this->client = $client;
32
3
}
33
34
/**
35
*
36
* @return Client
37
*/
38
3
public function getClient()
39
{
40
3
return $this->client;
41
}
42
43
/**
44
*
45
* @param RequestInterface $request
46
* @return Response
47
* @throws Exception\RequestException
48
*/
49
3
protected function getResponse(RequestInterface $request)
50
{
51
try {
52
/* @var $response \GuzzleHttp\Psr7\Response */
53
3
$response = $this->getClient()->send($request);
54
1
} catch (GuzzleHttpException $ex) {
55
1
throw new Exception\RequestException('Could not get valid response from "' . $request->getUri() . '"', null, $ex);
56
}
57
58
2
if ($response->getStatusCode() !== 200) {
59
1
throw new Exception\RequestException('Could not get valid response from "' . $request->getUri() . '". Status code is: "' . $response->getStatusCode() . '"');