Passed
Push — articleinfo-bot-percentages ( 0613da )
by MusikAnimal
09:12
created
src/AppBundle/Repository/ProjectRepository.php 2 patches
Indentation   +3 added lines, -3 removed lines patch added patch discarded remove patch
@@ -330,9 +330,9 @@
 block discarded – undo
330 330
     {
331 331
         $pageTable = $this->getTableName($project->getDatabaseName(), 'page');
332 332
         $query = "SELECT page_id "
333
-             . " FROM $pageTable "
334
-             . " WHERE page_namespace = :ns AND page_title = :title AND page_len > 0 "
335
-             . " LIMIT 1";
333
+                . " FROM $pageTable "
334
+                . " WHERE page_namespace = :ns AND page_title = :title AND page_len > 0 "
335
+                . " LIMIT 1";
336 336
         $params = [
337 337
             'ns' => $namespaceId,
338 338
             'title' => str_replace(' ', '_', $pageTitle),
Please login to merge, or discard this patch.
Spacing   +6 added lines, -6 removed lines patch added patch discarded remove patch
@@ -3,7 +3,7 @@  discard block
 block discarded – undo
3 3
  * This file contains only the ProjectRepository class.
4 4
  */
5 5
 
6
-declare(strict_types = 1);
6
+declare(strict_types=1);
7 7
 
8 8
 namespace AppBundle\Repository;
9 9
 
@@ -120,7 +120,7 @@  discard block
 block discarded – undo
120 120
         }
121 121
 
122 122
         if ($this->container->hasParameter("database_meta_table")) {
123
-            $table = $this->container->getParameter('database_meta_name') . '.' .
123
+            $table = $this->container->getParameter('database_meta_name').'.'.
124 124
                 $this->container->getParameter('database_meta_table');
125 125
         } else {
126 126
             $table = "meta_p.wiki";
@@ -168,7 +168,7 @@  discard block
 block discarded – undo
168 168
                     || $projMetadata['url'] == "https://$project"
169 169
                     || $projMetadata['url'] == "https://$project.org"
170 170
                     || $projMetadata['url'] == "https://www.$project") {
171
-                    $this->log->debug(__METHOD__ . " Using cached data for $project");
171
+                    $this->log->debug(__METHOD__." Using cached data for $project");
172 172
                     return $projMetadata;
173 173
                 }
174 174
             }
@@ -179,7 +179,7 @@  discard block
 block discarded – undo
179 179
         }
180 180
 
181 181
         if ($this->container->hasParameter("database_meta_table")) {
182
-            $table = $this->container->getParameter('database_meta_name') . '.' .
182
+            $table = $this->container->getParameter('database_meta_name').'.'.
183 183
                 $this->container->getParameter('database_meta_table');
184 184
         } else {
185 185
             $table = "meta_p.wiki";
@@ -323,7 +323,7 @@  discard block
 block discarded – undo
323 323
         $optedIn = $this->container->getParameter('opted_in');
324 324
         // In case there's just one given.
325 325
         if (!is_array($optedIn)) {
326
-            $optedIn = [ $optedIn ];
326
+            $optedIn = [$optedIn];
327 327
         }
328 328
         return $optedIn;
329 329
     }
@@ -392,7 +392,7 @@  discard block
 block discarded – undo
392 392
         ]])->getBody()->getContents(), true);
393 393
 
394 394
         $extensions = $res['query']['extensions'] ?? [];
395
-        return array_map(function ($extension) {
395
+        return array_map(function($extension) {
396 396
             return $extension['name'];
397 397
         }, $extensions);
398 398
     }
Please login to merge, or discard this patch.
src/AppBundle/Repository/AdminScoreRepository.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -3,7 +3,7 @@
 block discarded – undo
3 3
  * This file contains only the AdminScoreRepository class.
4 4
  */
5 5
 
6
-declare(strict_types = 1);
6
+declare(strict_types=1);
7 7
 
8 8
 namespace AppBundle\Repository;
9 9
 
Please login to merge, or discard this patch.
src/AppBundle/Controller/RfXAnalysisController.php 1 patch
Spacing   +4 added lines, -4 removed lines patch added patch discarded remove patch
@@ -112,12 +112,12 @@  discard block
 block discarded – undo
112 112
 
113 113
         // Construct the page name
114 114
         if (!isset($this->getParameter('rfx')[$domain]['pages'][$type])) {
115
-            $pageTitle= '';
115
+            $pageTitle = '';
116 116
         } else {
117
-            $pageTitle= $this->getParameter('rfx')[$domain]['pages'][$type];
117
+            $pageTitle = $this->getParameter('rfx')[$domain]['pages'][$type];
118 118
         }
119 119
 
120
-        $pageTitle.= '/'.$this->user->getUsername();
120
+        $pageTitle .= '/'.$this->user->getUsername();
121 121
         $page = new Page($this->project, $pageTitle);
122 122
         $pageRepo = new PageRepository();
123 123
         $pageRepo->setContainer($this->container);
@@ -145,7 +145,7 @@  discard block
 block discarded – undo
145 145
         $neutral = $rfx->getSection('neutral');
146 146
         $dup = $rfx->getDuplicates();
147 147
 
148
-        $total = count($support) + count($oppose) + count($neutral);
148
+        $total = count($support)+count($oppose)+count($neutral);
149 149
 
150 150
         if (0 === $total) {
151 151
             $this->addFlashMessage('notice', 'no-result', [$pageTitle]);
Please login to merge, or discard this patch.
src/AppBundle/Helper/I18nHelper.php 1 patch
Spacing   +4 added lines, -4 removed lines patch added patch discarded remove patch
@@ -3,7 +3,7 @@  discard block
 block discarded – undo
3 3
  * This file contains only the I18nHelper.
4 4
  */
5 5
 
6
-declare(strict_types = 1);
6
+declare(strict_types=1);
7 7
 
8 8
 namespace AppBundle\Helper;
9 9
 
@@ -74,7 +74,7 @@  discard block
 block discarded – undo
74 74
         }
75 75
 
76 76
         // Find the path, and complain if English doesn't exist.
77
-        $path = $this->container->getParameter('kernel.root_dir') . '/../i18n';
77
+        $path = $this->container->getParameter('kernel.root_dir').'/../i18n';
78 78
         if (!file_exists("$path/en.json")) {
79 79
             throw new Exception("Language directory doesn't exist: $path");
80 80
         }
@@ -129,7 +129,7 @@  discard block
 block discarded – undo
129 129
         $messageFiles = glob($this->container->getParameter('kernel.root_dir').'/../i18n/*.json');
130 130
 
131 131
         $languages = array_values(array_unique(array_map(
132
-            function ($filename) {
132
+            function($filename) {
133 133
                 return basename($filename, '.json');
134 134
             },
135 135
             $messageFiles
@@ -171,7 +171,7 @@  discard block
 block discarded – undo
171 171
             $this->getIntuition()->getLangFallbacks($this->getLang())
172 172
         );
173 173
 
174
-        return array_filter($fallbacks, function ($lang) use ($i18nPath) {
174
+        return array_filter($fallbacks, function($lang) use ($i18nPath) {
175 175
             return is_file($i18nPath.$lang.'.json');
176 176
         });
177 177
     }
Please login to merge, or discard this patch.
src/AppBundle/Repository/PageAssessmentsRepository.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -3,7 +3,7 @@
 block discarded – undo
3 3
  * This file contains only the PageAssessmentsRepository class.
4 4
  */
5 5
 
6
-declare(strict_types = 1);
6
+declare(strict_types=1);
7 7
 
8 8
 namespace AppBundle\Repository;
9 9
 
Please login to merge, or discard this patch.
src/AppBundle/Repository/AdminStatsRepository.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -3,7 +3,7 @@
 block discarded – undo
3 3
  * This file contains only the AdminStatsRepository class.
4 4
  */
5 5
 
6
-declare(strict_types = 1);
6
+declare(strict_types=1);
7 7
 
8 8
 namespace AppBundle\Repository;
9 9
 
Please login to merge, or discard this patch.
src/AppBundle/Repository/CategoryEditsRepository.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -3,7 +3,7 @@
 block discarded – undo
3 3
  * This file contains only the CategoryEditsRepository class.
4 4
  */
5 5
 
6
-declare(strict_types = 1);
6
+declare(strict_types=1);
7 7
 
8 8
 namespace AppBundle\Repository;
9 9
 
Please login to merge, or discard this patch.
src/AppBundle/Repository/UserRepository.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -3,7 +3,7 @@
 block discarded – undo
3 3
  * This file contains only the UserRepository class.
4 4
  */
5 5
 
6
-declare(strict_types = 1);
6
+declare(strict_types=1);
7 7
 
8 8
 namespace AppBundle\Repository;
9 9
 
Please login to merge, or discard this patch.
src/AppBundle/Model/Model.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -3,7 +3,7 @@
 block discarded – undo
3 3
  * This file contains only the Model class.
4 4
  */
5 5
 
6
-declare(strict_types = 1);
6
+declare(strict_types=1);
7 7
 
8 8
 namespace AppBundle\Model;
9 9
 
Please login to merge, or discard this patch.