@@ -8,14 +8,14 @@ |
||
8 | 8 | |
9 | 9 | class RequestTest extends \PHPUnit_Framework_TestCase |
10 | 10 | { |
11 | - /** |
|
12 | - * @var Client |
|
13 | - */ |
|
11 | + /** |
|
12 | + * @var Client |
|
13 | + */ |
|
14 | 14 | protected $client; |
15 | 15 | |
16 | - /** |
|
17 | - * @var Request |
|
18 | - */ |
|
16 | + /** |
|
17 | + * @var Request |
|
18 | + */ |
|
19 | 19 | protected $request; |
20 | 20 | |
21 | 21 | public function setUp() |
@@ -63,7 +63,7 @@ |
||
63 | 63 | 'Accept: application/json', |
64 | 64 | ); |
65 | 65 | if (!empty($this->auth_string)) { |
66 | - $this->headers[] = 'Authorization: Basic ' . base64_encode($this->auth_string); |
|
66 | + $this->headers[] = 'Authorization: Basic '.base64_encode($this->auth_string); |
|
67 | 67 | } |
68 | 68 | |
69 | 69 | // Add custom headers and set headers in cURL object. |
@@ -49,9 +49,9 @@ discard block |
||
49 | 49 | // Add query parameters to $path? |
50 | 50 | if (!empty($query)) { |
51 | 51 | if (strpos($path, '?') === false) { |
52 | - $path .= '?' . http_build_query($query, '', '&'); |
|
52 | + $path .= '?'.http_build_query($query, '', '&'); |
|
53 | 53 | } else { |
54 | - $path .= ini_get('arg_separator.output') . http_build_query($query, '', '&'); |
|
54 | + $path .= ini_get('arg_separator.output').http_build_query($query, '', '&'); |
|
55 | 55 | } |
56 | 56 | } |
57 | 57 | |
@@ -140,7 +140,7 @@ discard block |
||
140 | 140 | */ |
141 | 141 | protected function setUrl($params) |
142 | 142 | { |
143 | - curl_setopt($this->client->ch, CURLOPT_URL, Constants::API_URL . trim($params, '/')); |
|
143 | + curl_setopt($this->client->ch, CURLOPT_URL, Constants::API_URL.trim($params, '/')); |
|
144 | 144 | } |
145 | 145 | |
146 | 146 | /** |
@@ -159,7 +159,7 @@ discard block |
||
159 | 159 | curl_setopt($this->client->ch, CURLOPT_CUSTOMREQUEST, $request_type); |
160 | 160 | |
161 | 161 | // If additional data is delivered, we will send it along with the API request |
162 | - if (is_array($form) && ! empty($form)) { |
|
162 | + if (is_array($form) && !empty($form)) { |
|
163 | 163 | curl_setopt($this->client->ch, CURLOPT_POSTFIELDS, $this->httpBuildQuery($form)); |
164 | 164 | } |
165 | 165 |