@@ -93,12 +93,12 @@ discard block |
||
93 | 93 | |
94 | 94 | Timer\timeout($slack->connect(), 30, $this->getLoop()) |
95 | 95 | ->then([$this, 'connected']) |
96 | - ->otherwise(function (Timer\TimeoutException $error) { |
|
96 | + ->otherwise(function(Timer\TimeoutException $error) { |
|
97 | 97 | $this->getLog()->error($error->getMessage()); |
98 | 98 | $this->getLog()->error('Connection failed, shutting down.'); |
99 | 99 | $this->shutDown(); |
100 | 100 | }) |
101 | - ->otherwise(function ($error) { |
|
101 | + ->otherwise(function($error) { |
|
102 | 102 | $this->getLog()->error('Connection failed, shutting down.'); |
103 | 103 | $this->shutDown(); |
104 | 104 | }); |
@@ -125,11 +125,11 @@ discard block |
||
125 | 125 | } |
126 | 126 | |
127 | 127 | $this->getSlack()->reconnect()->then( |
128 | - function () { |
|
128 | + function() { |
|
129 | 129 | $this->getLog()->info('Reconnected'); |
130 | 130 | $this->monitor = $this->startConnectionMonitor(); |
131 | 131 | }, |
132 | - function () { |
|
132 | + function() { |
|
133 | 133 | $this->getLog()->error('Reconnect failed, shutting down.'); |
134 | 134 | $this->shutDown(); |
135 | 135 | } |
@@ -218,7 +218,7 @@ discard block |
||
218 | 218 | protected function logMessage($data) |
219 | 219 | { |
220 | 220 | if ($this->messageLog !== null) { |
221 | - file_put_contents($this->messageLog, json_encode($data) . "\n", FILE_APPEND); |
|
221 | + file_put_contents($this->messageLog, json_encode($data)."\n", FILE_APPEND); |
|
222 | 222 | } |
223 | 223 | } |
224 | 224 | |
@@ -234,7 +234,7 @@ discard block |
||
234 | 234 | |
235 | 235 | $this->ping(); |
236 | 236 | |
237 | - return $this->loop->addPeriodicTimer($interval, function () { |
|
237 | + return $this->loop->addPeriodicTimer($interval, function() { |
|
238 | 238 | $this->checkPong(); |
239 | 239 | $this->ping(); |
240 | 240 | }); |
@@ -267,7 +267,7 @@ discard block |
||
267 | 267 | |
268 | 268 | $this->getSlack()->ping() |
269 | 269 | ->then( |
270 | - function (Payload $payload) { |
|
270 | + function(Payload $payload) { |
|
271 | 271 | $this->getLog()->info($payload->toJson()); |
272 | 272 | $this->pong = true; |
273 | 273 | } |