@@ -192,7 +192,7 @@ discard block |
||
192 | 192 | foreach ($headers_list as $index => $headValue) { |
193 | 193 | @list($key, $value) = explode(": ", $headValue); |
194 | 194 | |
195 | - if (!is_null($key) && !is_null($value) ) { |
|
195 | + if (!is_null($key) && !is_null($value)) { |
|
196 | 196 | $headers_list[$key] = $value; |
197 | 197 | unset($headers_list[$index]); |
198 | 198 | } |
@@ -204,7 +204,7 @@ discard block |
||
204 | 204 | $apacheRequestHeaders = apache_request_headers(); |
205 | 205 | } |
206 | 206 | |
207 | - if( is_null($apacheRequestHeaders) || empty($apacheRequestHeaders) ) { |
|
207 | + if (is_null($apacheRequestHeaders) || empty($apacheRequestHeaders)) { |
|
208 | 208 | return []; |
209 | 209 | } |
210 | 210 | |
@@ -262,7 +262,7 @@ discard block |
||
262 | 262 | '*', |
263 | 263 | )); |
264 | 264 | |
265 | - if( !array_key_exists('Access-Control-Allow-Methods', $this->getHeaders()) ) { |
|
265 | + if (!array_key_exists('Access-Control-Allow-Methods', $this->getHeaders())) { |
|
266 | 266 | $this->setHeader('Access-Control-Allow-Methods', array( |
267 | 267 | 'GET,POST,OPTIONS', |
268 | 268 | )); |
@@ -77,7 +77,7 @@ discard block |
||
77 | 77 | { |
78 | 78 | $auth_headers = $this->getHeaders(); |
79 | 79 | |
80 | - if( $this->hasBearerValue() ) { |
|
80 | + if ($this->hasBearerValue()) { |
|
81 | 81 | |
82 | 82 | list($type, $clientToken) = explode(" ", $auth_headers["Authorization"], 2); |
83 | 83 | |
@@ -99,7 +99,7 @@ discard block |
||
99 | 99 | $helper = new helper; |
100 | 100 | |
101 | 101 | if (isset($auth_headers["Authorization"]) && !empty($auth_headers["Authorization"])) { |
102 | - if( $grantType = $helper->checkVal($_REQUEST, 'grant_type') ) { |
|
102 | + if ($grantType = $helper->checkVal($_REQUEST, 'grant_type')) { |
|
103 | 103 | |
104 | 104 | $refreshToken = false; |
105 | 105 | |
@@ -144,7 +144,7 @@ discard block |
||
144 | 144 | ) |
145 | 145 | ); |
146 | 146 | |
147 | - if( empty($account) ) { |
|
147 | + if (empty($account)) { |
|
148 | 148 | $this->setUnauthorised(); |
149 | 149 | } |
150 | 150 |