@@ -132,7 +132,7 @@ discard block |
||
132 | 132 | case 'POST': |
133 | 133 | curl_setopt(/** @scrutinizer ignore-type */ $ch, CURLOPT_POST, true); |
134 | 134 | if ($this->json === true) { |
135 | - $params = json_encode($params); |
|
135 | + $params = json_encode($params); |
|
136 | 136 | } |
137 | 137 | curl_setopt(/** @scrutinizer ignore-type */ $ch, CURLOPT_POSTFIELDS, $params); |
138 | 138 | break; |
@@ -165,21 +165,21 @@ discard block |
||
165 | 165 | |
166 | 166 | private function _json_encoder($params) |
167 | 167 | { |
168 | - if ($this->json === true) { |
|
169 | - return json_encode($params); |
|
170 | - } |
|
168 | + if ($this->json === true) { |
|
169 | + return json_encode($params); |
|
170 | + } |
|
171 | 171 | } |
172 | 172 | |
173 | 173 | private function _createHeaders($headers = null) |
174 | 174 | { |
175 | - $headers[] = $this->_api_key_var.$this->_api_key; |
|
176 | - if ($this->json === true) { |
|
177 | - $headers[] = 'Content-Type: application/json'; |
|
178 | - } |
|
179 | - if ($this->accept === true) { |
|
180 | - $headers[] = 'Accept: application/json'; |
|
181 | - } |
|
182 | - return $headers; |
|
175 | + $headers[] = $this->_api_key_var.$this->_api_key; |
|
176 | + if ($this->json === true) { |
|
177 | + $headers[] = 'Content-Type: application/json'; |
|
178 | + } |
|
179 | + if ($this->accept === true) { |
|
180 | + $headers[] = 'Accept: application/json'; |
|
181 | + } |
|
182 | + return $headers; |
|
183 | 183 | } |
184 | 184 | |
185 | 185 | private function _parseHeaders($raw_headers) |