@@ -59,7 +59,6 @@ |
||
| 59 | 59 | * @param GameDataStorage $gameData |
| 60 | 60 | * @param PlayerStorage $playerStorage |
| 61 | 61 | * @param LoggerInterface $logger |
| 62 | - * @param string $url |
|
| 63 | 62 | * @param int $pingInterval |
| 64 | 63 | * @param int $retryInterval |
| 65 | 64 | */ |
@@ -103,15 +103,15 @@ discard block |
||
| 103 | 103 | */ |
| 104 | 104 | protected function handshake() |
| 105 | 105 | { |
| 106 | - $key = &$this->key; |
|
| 107 | - $lastPing = &$this->lastPing; |
|
| 106 | + $key = &$this->key; |
|
| 107 | + $lastPing = &$this->lastPing; |
|
| 108 | 108 | $that = $this; |
| 109 | 109 | $logger = $this->logger; |
| 110 | 110 | |
| 111 | 111 | $query = http_build_query( |
| 112 | 112 | ['login' => $this->gameData->getSystemInfo()->serverLogin] |
| 113 | 113 | ); |
| 114 | - $url = $this->handshakeUrl . '?' . $query; |
|
| 114 | + $url = $this->handshakeUrl.'?'.$query; |
|
| 115 | 115 | |
| 116 | 116 | $lastPing = time(); |
| 117 | 117 | $this->logger->debug("[eXpansion analytics]Starting handshake"); |
@@ -120,7 +120,7 @@ discard block |
||
| 120 | 120 | $this->http->put( |
| 121 | 121 | $url, |
| 122 | 122 | [], |
| 123 | - function (HttpResult $result) use (&$key, &$lastPing, $logger, $that) { |
|
| 123 | + function(HttpResult $result) use (&$key, &$lastPing, $logger, $that) { |
|
| 124 | 124 | $key = null; |
| 125 | 125 | if ($result->getHttpCode() != '200') { |
| 126 | 126 | $logger->debug('[eXpansion analytics]Handshake failed', ['http_code' => $result->getHttpCode()]); |
@@ -160,7 +160,7 @@ discard block |
||
| 160 | 160 | $query = http_build_query( |
| 161 | 161 | $data |
| 162 | 162 | ); |
| 163 | - $url = $this->pingUrl . '?' . $query; |
|
| 163 | + $url = $this->pingUrl.'?'.$query; |
|
| 164 | 164 | |
| 165 | 165 | $this->operationInProgress = true; |
| 166 | 166 | $this->lastPing = time(); |
@@ -172,7 +172,7 @@ discard block |
||
| 172 | 172 | $this->http->put( |
| 173 | 173 | $url, |
| 174 | 174 | [], |
| 175 | - function (HttpResult $result) use (&$operationInProgress, &$key, $logger) { |
|
| 175 | + function(HttpResult $result) use (&$operationInProgress, &$key, $logger) { |
|
| 176 | 176 | if ($result->getHttpCode() == '200') { |
| 177 | 177 | $operationInProgress = false; |
| 178 | 178 | $logger->debug('[eXpansion analytics]Ping successfull'); |
@@ -202,7 +202,7 @@ discard block |
||
| 202 | 202 | 'memory' => memory_get_usage(), |
| 203 | 203 | 'memory_peak' => memory_get_peak_usage(), |
| 204 | 204 | 'build' => '', |
| 205 | - 'title' => str_replace('@','_by_', $this->gameData->getVersion()->titleId), |
|
| 205 | + 'title' => str_replace('@', '_by_', $this->gameData->getVersion()->titleId), |
|
| 206 | 206 | 'game' => $this->gameData->getTitle(), |
| 207 | 207 | 'mode' => strtolower($this->gameData->getGameInfos()->scriptName), |
| 208 | 208 | 'serverOs' => $this->gameData->getServerOs(), |