@@ -121,12 +121,12 @@ discard block |
||
121 | 121 | $curlMessage = 'Extension CURL is not loaded or not installed.'; |
122 | 122 | |
123 | 123 | // check if auth is null |
124 | - if (! is_object($auth) || null == $auth) { |
|
124 | + if (!is_object($auth) || null == $auth) { |
|
125 | 125 | trigger_error($authMessage, E_USER_ERROR); |
126 | 126 | } |
127 | 127 | |
128 | 128 | // check if extension is installed |
129 | - if (! extension_loaded('curl')) { |
|
129 | + if (!extension_loaded('curl')) { |
|
130 | 130 | trigger_error($curlMessage, E_USER_ERROR); |
131 | 131 | } |
132 | 132 | } |
@@ -187,7 +187,7 @@ discard block |
||
187 | 187 | $headers['Content-Type'] = 'application/json'; |
188 | 188 | |
189 | 189 | // check if header is an array |
190 | - if (! is_array($headers)) { |
|
190 | + if (!is_array($headers)) { |
|
191 | 191 | $str = "The guzzle client headers must be an array."; |
192 | 192 | throw new \Exception($str); |
193 | 193 | } |
@@ -241,7 +241,7 @@ discard block |
||
241 | 241 | |
242 | 242 | $path = ltrim($path, '/'); |
243 | 243 | |
244 | - return $path . '.json?auth='. $auth.'&'. http_build_query($options).''; |
|
244 | + return $path . '.json?auth=' . $auth . '&' . http_build_query($options) . ''; |
|
245 | 245 | } |
246 | 246 | |
247 | 247 | /** |
@@ -442,7 +442,7 @@ discard block |
||
442 | 442 | */ |
443 | 443 | private function writeEventLogs($logger, $eventData, $event, $path) |
444 | 444 | { |
445 | - if (! empty($eventData) || null != $eventData) { |
|
445 | + if (!empty($eventData) || null != $eventData) { |
|
446 | 446 | $logger->addDebug("path: {$path}", [ |
447 | 447 | 'DATA' => $eventData, |
448 | 448 | 'EVENT TYPE' => $event->getEventType() |
@@ -172,7 +172,7 @@ |
||
172 | 172 | ]); |
173 | 173 | |
174 | 174 | } catch (\GuzzleException $e) { |
175 | - die((string)$e->getResponse()->getBody()); |
|
175 | + die((string) $e->getResponse()->getBody()); |
|
176 | 176 | } |
177 | 177 | |
178 | 178 | } |
@@ -24,15 +24,15 @@ |
||
24 | 24 | |
25 | 25 | $now = time(); |
26 | 26 | |
27 | - $opt = [];//orderBy="$value"&startAt=50 |
|
28 | - $opt['orderBy'] ="timestamp"; |
|
27 | + $opt = []; //orderBy="$value"&startAt=50 |
|
28 | + $opt['orderBy'] = "timestamp"; |
|
29 | 29 | $opt['startAt'] = $yesterday; |
30 | - $opt['endAt'] =$now; |
|
30 | + $opt['endAt'] = $now; |
|
31 | 31 | //$opt['equalTo'] ='2214791644'; |
32 | 32 | //startAt="b"&endAt="b\uf8ff" |
33 | 33 | |
34 | 34 | |
35 | -function test(...$params){ |
|
35 | +function test(...$params) { |
|
36 | 36 | // pass event to callback function |
37 | 37 | |
38 | 38 | print_r($params[0]); |