Passed
Branch develop (226e06)
by BENARD
09:42
created
src/Admin/ProofRequestAdmin.php 2 patches
Indentation   +13 added lines, -13 removed lines patch added patch discarded remove patch
@@ -44,9 +44,9 @@  discard block
 block discarded – undo
44 44
         $this->container = $container;
45 45
     }
46 46
 
47
-     /**
48
-     * @return string
49
-     */
47
+        /**
48
+         * @return string
49
+         */
50 50
     private function getLibGame(): string
51 51
     {
52 52
         $locale = Locale::getDefault();
@@ -151,19 +151,19 @@  discard block
 block discarded – undo
151 151
                 ]
152 152
             ])
153 153
             ->add('playerChart.player', ModelFilter::class, [
154
-                 'field_type' => ModelAutocompleteType::class,
155
-                 'field_options' => ['property'=>'pseudo'],
156
-                 'label' => 'label.player',
154
+                    'field_type' => ModelAutocompleteType::class,
155
+                    'field_options' => ['property'=>'pseudo'],
156
+                    'label' => 'label.player',
157 157
             ])
158 158
             ->add('playerRequesting', ModelFilter::class, [
159
-                 'field_type' => ModelAutocompleteType::class,
160
-                 'field_options' => ['property'=>'pseudo'],
161
-                 'label' => 'label.player.requesting',
159
+                    'field_type' => ModelAutocompleteType::class,
160
+                    'field_options' => ['property'=>'pseudo'],
161
+                    'label' => 'label.player.requesting',
162 162
             ])
163 163
             ->add('playerResponding', ModelFilter::class, [
164
-                 'field_type' => ModelAutocompleteType::class,
165
-                 'field_options' => ['property'=>'pseudo'],
166
-                 'label' => 'label.player.responding',
164
+                    'field_type' => ModelAutocompleteType::class,
165
+                    'field_options' => ['property'=>'pseudo'],
166
+                    'label' => 'label.player.responding',
167 167
             ]);
168 168
     }
169 169
 
@@ -195,7 +195,7 @@  discard block
 block discarded – undo
195 195
                     array('fieldName' => 'player'),
196 196
                 )
197 197
             ])
198
-             ->add('playerChart.chart.group.game', null, [
198
+                ->add('playerChart.chart.group.game', null, [
199 199
                 'associated_property' =>  $this->getLibGame(),
200 200
                 'label' => 'label.name',
201 201
                 'sortable' => true,
Please login to merge, or discard this patch.
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -39,7 +39,7 @@  discard block
 block discarded – undo
39 39
         $this->messager = $messager;
40 40
     }
41 41
 
42
-    public function setContainer (ContainerInterface $container)
42
+    public function setContainer(ContainerInterface $container)
43 43
     {
44 44
         $this->container = $container;
45 45
     }
@@ -267,7 +267,7 @@  discard block
 block discarded – undo
267 267
      */
268 268
     public function preValidate($object): void
269 269
     {
270
-        $player =  $this->getPlayer();
270
+        $player = $this->getPlayer();
271 271
 
272 272
         if ($player) {
273 273
             if (($object->getPlayerRequesting()->getId() === $player->getId())
Please login to merge, or discard this patch.
src/Doctrine/TranslationExtension.php 1 patch
Indentation   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -61,6 +61,6 @@
 block discarded – undo
61 61
             $locale = 'en';
62 62
         }
63 63
         $queryBuilder->leftJoin('o.translations', 't', 'WITH', "t.locale='$locale'")
64
-           ->addSelect('t');
64
+            ->addSelect('t');
65 65
     }
66 66
 }
Please login to merge, or discard this patch.
src/Repository/GameRepository.php 1 patch
Indentation   +7 added lines, -7 removed lines patch added patch discarded remove patch
@@ -25,12 +25,12 @@  discard block
 block discarded – undo
25 25
      */
26 26
     public function getIds() : array
27 27
     {
28
-         return $this->createQueryBuilder('game')
29
-             ->select('game.id')
30
-             ->where('game.status = :status')
31
-             ->setParameter('status', Game::STATUS_ACTIVE)
32
-             ->getQuery()
33
-             ->getResult(AbstractQuery::HYDRATE_ARRAY);
28
+            return $this->createQueryBuilder('game')
29
+                ->select('game.id')
30
+                ->where('game.status = :status')
31
+                ->setParameter('status', Game::STATUS_ACTIVE)
32
+                ->getQuery()
33
+                ->getResult(AbstractQuery::HYDRATE_ARRAY);
34 34
     }
35 35
 
36 36
     /**
@@ -261,7 +261,7 @@  discard block
 block discarded – undo
261 261
      */
262 262
     private function getCountQueryBuilder(): QueryBuilder
263 263
     {
264
-         return $this->createQueryBuilder('g')
264
+            return $this->createQueryBuilder('g')
265 265
             ->select('COUNT(g.id)');
266 266
     }
267 267
 
Please login to merge, or discard this patch.
src/Repository/TeamBadgeRepository.php 1 patch
Indentation   +5 added lines, -5 removed lines patch added patch discarded remove patch
@@ -33,11 +33,11 @@
 block discarded – undo
33 33
     }
34 34
 
35 35
 
36
-     /**
37
-     * @param array $teams
38
-     * @param Badge $badge
39
-     * @throws Exception
40
-     */
36
+        /**
37
+         * @param array $teams
38
+         * @param Badge $badge
39
+         * @throws Exception
40
+         */
41 41
     public function updateBadge(array $teams, Badge $badge)
42 42
     {
43 43
         //----- get players with badge
Please login to merge, or discard this patch.
src/Repository/PlayerChartLibRepository.php 1 patch
Indentation   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -103,7 +103,7 @@
 block discarded – undo
103 103
     /**
104 104
      * @return QueryBuilder
105 105
      */
106
-   /* private function getScoreQuery(): QueryBuilder
106
+    /* private function getScoreQuery(): QueryBuilder
107 107
     {
108 108
         return $this->createQueryBuilder('pcl')
109 109
             ->join('pcl.libChart', 'lib')
Please login to merge, or discard this patch.
src/Repository/ChartRepository.php 1 patch
Indentation   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -112,7 +112,7 @@  discard block
 block discarded – undo
112 112
     public function getTopScore($group, $player, string $locale = 'en'): mixed
113 113
     {
114 114
         $query = $this->createQueryBuilder('ch')
115
-             ->join('ch.group', 'gr')
115
+                ->join('ch.group', 'gr')
116 116
             ->addSelect('gr')
117 117
             ->addSelect('pc')
118 118
             ->andWhere('ch.group = :group')
@@ -139,7 +139,7 @@  discard block
 block discarded – undo
139 139
      */
140 140
     private function getCountQueryBuilder(): QueryBuilder
141 141
     {
142
-         return $this->createQueryBuilder('c')
142
+            return $this->createQueryBuilder('c')
143 143
             ->select('COUNT(c.id)');
144 144
     }
145 145
 
Please login to merge, or discard this patch.
src/Tools/Score.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -17,7 +17,7 @@  discard block
 block discarded – undo
17 17
         $arrayParts = explode('|', $mask);
18 18
         foreach ($arrayParts as $partOfMask) {
19 19
             $arrayLib = explode('~', $partOfMask);
20
-            $result[] = ['size' => (int)$arrayLib[0], 'suffixe' => $arrayLib[1]];
20
+            $result[] = ['size' => (int) $arrayLib[0], 'suffixe' => $arrayLib[1]];
21 21
         }
22 22
 
23 23
         return $result;
@@ -35,7 +35,7 @@  discard block
 block discarded – undo
35 35
     {
36 36
         $parse   = self::parseChartMask($mask);
37 37
         $negative = 0 === strpos($value, '-');
38
-        $value = $negative ? (int)substr($value, 1) : $value;
38
+        $value = $negative ? (int) substr($value, 1) : $value;
39 39
         $data    = [];
40 40
         $laValue = $value;
41 41
         for ($k = count($parse) - 1; $k >= 0; $k--) {
Please login to merge, or discard this patch.
src/Tools/Ranking.php 2 patches
Indentation   +5 added lines, -5 removed lines patch added patch discarded remove patch
@@ -159,11 +159,11 @@
 block discarded – undo
159 159
         return $liste;
160 160
     }
161 161
 
162
-     /**
163
-     * Renvoie le tableau des points platform
164
-     * @param $iNbPartcipant
165
-     * @return array
166
-     */
162
+        /**
163
+         * Renvoie le tableau des points platform
164
+         * @param $iNbPartcipant
165
+         * @return array
166
+         */
167 167
     public static function platformPointProvider($iNbPartcipant): array
168 168
     {
169 169
         return self::chartPointProvider($iNbPartcipant);
Please login to merge, or discard this patch.
Spacing   +7 added lines, -7 removed lines patch added patch discarded remove patch
@@ -137,20 +137,20 @@  discard block
 block discarded – undo
137 137
     {
138 138
         $liste       = [];
139 139
         $pointRecord = 100 * $iNbPartcipant;
140
-        $nb          = 80;// % différence entre deux positions
141
-        $compteur    = 0;// compteur de position
140
+        $nb          = 80; // % différence entre deux positions
141
+        $compteur    = 0; // compteur de position
142 142
 
143 143
         // 1er
144 144
         $liste[1] = $pointRecord;
145 145
 
146 146
         for ($i = 2; $i <= $iNbPartcipant; $i++) {
147
-            $pointRecord = (int)($pointRecord * $nb / 100);
147
+            $pointRecord = (int) ($pointRecord * $nb / 100);
148 148
             $liste[$i]   = $pointRecord;
149 149
             $compteur++;
150 150
 
151 151
             if ($nb < 85) {
152 152
                 if ($compteur === 2) {
153
-                    $nb++;// le % augmente donc la différence diminue
153
+                    $nb++; // le % augmente donc la différence diminue
154 154
                     $compteur = 0;
155 155
                 }
156 156
             } elseif ($nb < 99) {
@@ -212,12 +212,12 @@  discard block
 block discarded – undo
212 212
 
213 213
             //If firsts
214 214
             if ($aArray[$i][$nameRankCol] == 1) {
215
-                $aArray[$i][$sNameNewCol] = (int)round($f, 0);
215
+                $aArray[$i][$sNameNewCol] = (int) round($f, 0);
216 216
                 continue;
217 217
             }
218 218
             //If non equals
219 219
             if ($aArray[$i][$nameEqualCol] == 1) {
220
-                $aArray[$i][$sNameNewCol] = (int)round($aF[$aArray[$i][$nameRankCol]], 0);
220
+                $aArray[$i][$sNameNewCol] = (int) round($aF[$aArray[$i][$nameRankCol]], 0);
221 221
                 continue;
222 222
             }
223 223
             //If equals (do average of players gives if they weren't tied)
@@ -227,7 +227,7 @@  discard block
 block discarded – undo
227 227
             }
228 228
             $value = round(array_sum($aTiedValues) / count($aTiedValues), 0);
229 229
             for ($j = $i, $nb = $i + count($aTiedValues); $j < $nb; ++$j) {
230
-                $aArray[$i][$sNameNewCol] = (int)$value;
230
+                $aArray[$i][$sNameNewCol] = (int) $value;
231 231
                 $i++;
232 232
             }
233 233
             $i--;
Please login to merge, or discard this patch.
src/Entity/Player.php 1 patch
Indentation   -1 removed lines patch added patch discarded remove patch
@@ -89,7 +89,6 @@
 block discarded – undo
89 89
     private string $avatar = 'default.jpg';
90 90
 
91 91
     /**
92
-
93 92
      * @ORM\Column(name="gamerCard", type="string", length=50, nullable=true)
94 93
      */
95 94
     private ?string $gamerCard;
Please login to merge, or discard this patch.