Test Failed
Push — link-to-mw-docs ( 66dd99 )
by MusikAnimal
13:45
created
src/AppBundle/Controller/XtoolsController.php 1 patch
Spacing   +4 added lines, -4 removed lines patch added patch discarded remove patch
@@ -201,7 +201,7 @@  discard block
 block discarded – undo
201 201
             throw new XtoolsHttpException(
202 202
                 $this->i18n->msg('not-opted-in', [
203 203
                     $this->getOptedInPage()->getTitle(),
204
-                    $this->i18n->msg('not-opted-in-link') .
204
+                    $this->i18n->msg('not-opted-in-link').
205 205
                         ' <https://www.mediawiki.org/wiki/XTools/Edit_Counter#restricted_stats>',
206 206
                     $this->i18n->msg('not-opted-in-login'),
207 207
                 ]),
@@ -640,7 +640,7 @@  discard block
 block discarded – undo
640 640
         $params = $this->convertLegacyParams($params);
641 641
 
642 642
         // Remove blank values.
643
-        return array_filter($params, function ($param) {
643
+        return array_filter($params, function($param) {
644 644
             // 'namespace' or 'username' could be '0'.
645 645
             return null !== $param && '' !== $param;
646 646
         });
@@ -836,7 +836,7 @@  discard block
 block discarded – undo
836 836
         $response->setStatusCode(Response::HTTP_OK);
837 837
 
838 838
         $elapsedTime = round(
839
-            microtime(true) - $this->request->server->get('REQUEST_TIME_FLOAT'),
839
+            microtime(true)-$this->request->server->get('REQUEST_TIME_FLOAT'),
840 840
             3
841 841
         );
842 842
 
@@ -879,7 +879,7 @@  discard block
 block discarded – undo
879 879
         $conn = $this->container->get('doctrine')
880 880
             ->getManager('default')
881 881
             ->getConnection();
882
-        $date =  date('Y-m-d');
882
+        $date = date('Y-m-d');
883 883
 
884 884
         // Increment count in timeline
885 885
         $existsSql = "SELECT 1 FROM usage_api_timeline
Please login to merge, or discard this patch.
src/AppBundle/EventSubscriber/RateLimitSubscriber.php 1 patch
Spacing   +5 added lines, -5 removed lines patch added patch discarded remove patch
@@ -3,7 +3,7 @@  discard block
 block discarded – undo
3 3
  * This file contains only the RateLimitSubscriber class.
4 4
  */
5 5
 
6
-declare(strict_types = 1);
6
+declare(strict_types=1);
7 7
 
8 8
 namespace AppBundle\EventSubscriber;
9 9
 
@@ -137,7 +137,7 @@  discard block
 block discarded – undo
137 137
         $cacheItem = $this->cache->getItem($cacheKey);
138 138
 
139 139
         // If increment value already in cache, or start with 1.
140
-        $count = $cacheItem->isHit() ? (int) $cacheItem->get() + 1 : 1;
140
+        $count = $cacheItem->isHit() ? (int)$cacheItem->get()+1 : 1;
141 141
 
142 142
         // Check if limit has been exceeded, and if so, throw an error.
143 143
         if ($count > $this->rateLimit) {
@@ -177,7 +177,7 @@  discard block
 block discarded – undo
177 177
         $cacheItem = $this->cache->getItem($cacheKey);
178 178
 
179 179
         // If increment value already in cache, or start with 1.
180
-        $count = $cacheItem->isHit() ? (int)$cacheItem->get() + 1 : 1;
180
+        $count = $cacheItem->isHit() ? (int)$cacheItem->get()+1 : 1;
181 181
 
182 182
         // Check if limit has been exceeded, and if so, add a log entry.
183 183
         if ($count > 3) {
@@ -252,8 +252,8 @@  discard block
 block discarded – undo
252 252
         $message = $this->i18n->msg('error-rate-limit', [
253 253
             $this->rateDuration,
254 254
             "<a href='/login'>".$this->i18n->msg('error-rate-limit-login')."</a>",
255
-            "<a href='https://www.mediawiki.org/wiki/Special:MyLanguage/XTools/API' target='_blank'>" .
256
-                $this->i18n->msg('api') .
255
+            "<a href='https://www.mediawiki.org/wiki/Special:MyLanguage/XTools/API' target='_blank'>".
256
+                $this->i18n->msg('api').
257 257
             "</a>",
258 258
         ]);
259 259
 
Please login to merge, or discard this patch.