@@ -123,6 +123,9 @@ discard block |
||
| 123 | 123 | return $readable ? $readable : $entity; |
| 124 | 124 | } |
| 125 | 125 | |
| 126 | + /** |
|
| 127 | + * @param string $readable |
|
| 128 | + */ |
|
| 126 | 129 | public function formatUser(string $entity, $readable = null) : string |
| 127 | 130 | { |
| 128 | 131 | if ($readable) { |
@@ -137,6 +140,9 @@ discard block |
||
| 137 | 140 | return $entity; |
| 138 | 141 | } |
| 139 | 142 | |
| 143 | + /** |
|
| 144 | + * @param string $readable |
|
| 145 | + */ |
|
| 140 | 146 | public function formatChannel(string $entity, $readable = null) : string |
| 141 | 147 | { |
| 142 | 148 | if ($readable) { |
@@ -26,7 +26,7 @@ |
||
| 26 | 26 | $clientFactory = new ReactAwareGuzzleClientFactory(); |
| 27 | 27 | $reactAwareCurlFactory = $clientFactory->createReactAwareCurlFactory($this->eventLoop, null, $this->logger); |
| 28 | 28 | $handler = $reactAwareCurlFactory->getHandler(); |
| 29 | - $handlerStack = $this->createHandlerStack($handler); |
|
| 29 | + $handlerStack = $this->createHandlerStack($handler); |
|
| 30 | 30 | $config['handler'] = $handlerStack; |
| 31 | 31 | |
| 32 | 32 | return new Client($config); |
@@ -172,7 +172,7 @@ discard block |
||
| 172 | 172 | protected function logMessage($data) |
| 173 | 173 | { |
| 174 | 174 | if ($this->messageLog !== null) { |
| 175 | - file_put_contents($this->messageLog, json_encode($data) . "\n", FILE_APPEND); |
|
| 175 | + file_put_contents($this->messageLog, json_encode($data)."\n", FILE_APPEND); |
|
| 176 | 176 | } |
| 177 | 177 | } |
| 178 | 178 | |
@@ -180,7 +180,7 @@ discard block |
||
| 180 | 180 | { |
| 181 | 181 | if ($interval = $this->get('connection_monitor.interval')) { |
| 182 | 182 | $this->getLog()->info("Monitoring websocket connection every $interval seconds."); |
| 183 | - $this->loop->addPeriodicTimer($interval, function () { |
|
| 183 | + $this->loop->addPeriodicTimer($interval, function() { |
|
| 184 | 184 | static $pong = true; |
| 185 | 185 | if (!$pong) { |
| 186 | 186 | $this->getLog()->error('Connection failed: no pong!'); |
@@ -188,7 +188,7 @@ discard block |
||
| 188 | 188 | } |
| 189 | 189 | $this->getSlack()->getRealTimeClient()->ping() |
| 190 | 190 | ->then( |
| 191 | - function (Payload $payload) use (&$pong) { |
|
| 191 | + function(Payload $payload) use (&$pong) { |
|
| 192 | 192 | $this->getLog()->info($payload->toJson()); |
| 193 | 193 | $pong = true; |
| 194 | 194 | } |