Conditions | 3 |
Paths | 3 |
Total Lines | 12 |
Code Lines | 6 |
Lines | 0 |
Ratio | 0 % |
Tests | 7 |
CRAP Score | 3 |
Changes | 0 |
1 | <?php |
||
50 | 1 | public function get($path, array $options = []) |
|
51 | { |
||
52 | 1 | if ($this->app_client) { |
|
53 | 1 | $options['headers'] = isset($options['headers']) ? $options['headers'] : []; |
|
54 | 1 | $options['headers']['User-Agent'] = $this->app_client; |
|
55 | } |
||
56 | |||
57 | 1 | $response = $this->client->request('GET', $this->host.$path, $options); |
|
58 | |||
59 | 1 | $content = $response->getBody()->getContents(); |
|
60 | |||
61 | 1 | return $content; |
|
62 | } |
||
64 |