Passed
Pull Request — master (#100)
by Bob
17:47
created
src/plugins/onTick/notifications.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -172,7 +172,7 @@
 block discarded – undo
172 172
                 $this->fuelChannel = $this->toDiscordChannel;
173 173
             }
174 174
             //Set timer for next key based on number of keys
175
-            $nextKey = (1900 / (int)$this->numberOfKeys) + time();
175
+            $nextKey = (1900 / (int) $this->numberOfKeys) + time();
176 176
             $nextKeyTime = gmdate("Y-m-d H:i:s", $nextKey);
177 177
             setPermCache("notificationsLastChecked", $nextKey);
178 178
             //Set cache timer for api key
Please login to merge, or discard this patch.
src/plugins/onTick/evemails.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -146,7 +146,7 @@
 block discarded – undo
146 146
         $cacheClr = $baseUnix - 13500;
147 147
 
148 148
         //Set timer for next key based on number of keys
149
-        $nextKey = (1900 / (int)$this->numberOfKeys) + time();
149
+        $nextKey = (1900 / (int) $this->numberOfKeys) + time();
150 150
         $nextKeyTime = gmdate("Y-m-d H:i:s", $nextKey);
151 151
         setPermCache("mailLastChecked", $nextKey);
152 152
 
Please login to merge, or discard this patch.
Dramiel.php 1 patch
Spacing   +4 added lines, -4 removed lines patch added patch discarded remove patch
@@ -158,21 +158,21 @@  discard block
 block discarded – undo
158 158
         $discord->updatePresence($game);
159 159
 
160 160
         // Server Status Check (tick plugins will not run if eve is offline)
161
-        $discord->loop->addPeriodicTimer(60, function () use ($logger) {
161
+        $discord->loop->addPeriodicTimer(60, function() use ($logger) {
162 162
             $crestData = json_decode(downloadData('https://crest-tq.eveonline.com/'), true);
163 163
             $crestStatus = isset($crestData['serviceStatus']) ? $crestData['serviceStatus'] : 'offline';
164 164
             setPermCache('serverState', $crestStatus);
165 165
         });
166 166
 
167 167
         // Run the Tick plugins
168
-        $discord->loop->addPeriodicTimer(3, function () use ($pluginsT) {
168
+        $discord->loop->addPeriodicTimer(3, function() use ($pluginsT) {
169 169
             foreach ($pluginsT as $plugin) {
170 170
                 $plugin->tick();
171 171
             }
172 172
         });
173 173
 
174 174
         // Message queue
175
-        $discord->loop->addPeriodicTimer(7, function () use ($discord, $logger) {
175
+        $discord->loop->addPeriodicTimer(7, function() use ($discord, $logger) {
176 176
             $x = 0;
177 177
             while ($x < 3) {
178 178
                 $id = getOldestMessage();
@@ -228,7 +228,7 @@  discard block
 block discarded – undo
228 228
         });
229 229
 
230 230
         // Mem cleanup every 30 minutes
231
-        $discord->loop->addPeriodicTimer(1800, function () use ($logger) {
231
+        $discord->loop->addPeriodicTimer(1800, function() use ($logger) {
232 232
             $logger->addInfo('Memory in use: ' . memory_get_usage() / 1024 / 1024 . 'MB');
233 233
             gc_collect_cycles(); // Collect garbage
234 234
             $logger->addInfo('Memory in use after garbage collection: ' . memory_get_usage() / 1024 / 1024 . 'MB');
Please login to merge, or discard this patch.
src/plugins/onTick/authCheck.php 1 patch
Spacing   +6 added lines, -6 removed lines patch added patch discarded remove patch
@@ -154,10 +154,10 @@  discard block
 block discarded – undo
154 154
         //Set corp/ally id arrays
155 155
         foreach ($this->authGroups as $authGroup) {
156 156
             if ($authGroup['corpID'] !== 0) {
157
-                $corpArray[] = (int)$authGroup['corpID'];
157
+                $corpArray[] = (int) $authGroup['corpID'];
158 158
             }
159 159
             if ($authGroup['allianceID'] !== 0) {
160
-                $allianceArray[] = (int)$authGroup['allianceID'];
160
+                $allianceArray[] = (int) $authGroup['allianceID'];
161 161
             }
162 162
         }
163 163
 
@@ -292,7 +292,7 @@  discard block
 block discarded – undo
292 292
         $guild = $this->discord->guilds->get('id', $this->guildID);
293 293
 
294 294
         //Get name queue status
295
-        $x = (int)getPermCache('nameQueueState');
295
+        $x = (int) getPermCache('nameQueueState');
296 296
 
297 297
         //Establish connection to mysql
298 298
         $conn = new mysqli($this->db, $this->dbUser, $this->dbPass, $this->dbName);
@@ -351,10 +351,10 @@  discard block
 block discarded – undo
351 351
                         foreach ($xml->result->rowset->row as $character) {
352 352
                             $corpInfo = getCorpInfo($character->attributes()->corporationID);
353 353
                             if (null !== $corpInfo) {
354
-                                $corpTicker = (string)$corpInfo['corpTicker'];
354
+                                $corpTicker = (string) $corpInfo['corpTicker'];
355 355
                                 if ($this->nameEnforce === 'true') {
356 356
                                     $nick = "[{$corpTicker}] {$eveName}";
357
-                                } elseif ((string)$nickName === "[{$corpTicker}]") {
357
+                                } elseif ((string) $nickName === "[{$corpTicker}]") {
358 358
                                     $nick = "[{$corpTicker}] {$userName}";
359 359
                                 } elseif (strpos($nickName, $corpTicker) == false) {
360 360
                                     $nick = "[{$corpTicker}] {$nickName}";
@@ -377,7 +377,7 @@  discard block
 block discarded – undo
377 377
                             }
378 378
                             if ($this->nameEnforce === 'true') {
379 379
                                 $nick = "[{$corpTicker}] {$eveName}";
380
-                            } elseif ((string)$nickName === "[{$corpTicker}]") {
380
+                            } elseif ((string) $nickName === "[{$corpTicker}]") {
381 381
                                 $nick = "[{$corpTicker}] {$userName}";
382 382
                             } elseif (strpos($nickName, $corpTicker) == false) {
383 383
                                 $nick = "[{$corpTicker}] {$nickName}";
Please login to merge, or discard this patch.