Passed
Push — master ( a7220b...7d0515 )
by Julien
01:21 queued 15s
created
src/Models/PreliminaryFight.php 1 patch
Doc Comments   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -57,7 +57,7 @@
 block discarded – undo
57 57
     /**
58 58
      * Save a Fight.
59 59
      *
60
-     * @param Collection $group
60
+     * @param FightersGroup $group
61 61
      * @param int        $numGroup
62 62
      * @param int        $order
63 63
      */
Please login to merge, or discard this patch.
src/TreeGen/TreeGen.php 1 patch
Doc Comments   +5 added lines, -2 removed lines patch added patch discarded remove patch
@@ -21,6 +21,9 @@  discard block
 block discarded – undo
21 21
 
22 22
     abstract protected function generateFights();
23 23
 
24
+    /**
25
+     * @param string|null $fighterToUpdate
26
+     */
24 27
     abstract protected function addFighterToGroup(FightersGroup $group, $fighter, $fighterToUpdate);
25 28
 
26 29
     abstract protected function getByeGroup($fighters);
@@ -82,7 +85,7 @@  discard block
 block discarded – undo
82 85
      * Get the size the first round will have.
83 86
      *
84 87
      * @param $fighterCount
85
-     * @param $groupSize
88
+     * @param integer $groupSize
86 89
      *
87 90
      * @return int
88 91
      */
@@ -200,7 +203,7 @@  discard block
 block discarded – undo
200 203
     /**
201 204
      * Logically build the tree ( attach a parent to every child for nestedSet Navigation ).
202 205
      *
203
-     * @param $numFighters
206
+     * @param integer $numFighters
204 207
      */
205 208
     protected function addParentToChildren($numFighters)
206 209
     {
Please login to merge, or discard this patch.
src/TreeGen/SingleEliminationTreeGen.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -226,7 +226,7 @@  discard block
 block discarded – undo
226 226
         $bye = $this->createByeFighter();
227 227
         $groupSize = $this->firstRoundGroupSize();
228 228
         $frequency = $groupSize != 0
229
-            ? (int) floor(count($fighters) / $groupSize / $groupSize)
229
+            ? (int)floor(count($fighters) / $groupSize / $groupSize)
230 230
             : -1;
231 231
         if ($frequency < $groupSize) {
232 232
             $frequency = $groupSize;
@@ -305,7 +305,7 @@  discard block
 block discarded – undo
305 305
     private function getMaxFightersByEntity($userGroups): int
306 306
     {
307 307
         return $userGroups
308
-            ->sortByDesc(function ($group) {
308
+            ->sortByDesc(function($group) {
309 309
                 return $group->count();
310 310
             })
311 311
             ->first()
Please login to merge, or discard this patch.
src/TreeGen/CreateSingleEliminationTree.php 1 patch
Spacing   +5 added lines, -5 removed lines patch added patch discarded remove patch
@@ -28,7 +28,7 @@  discard block
 block discarded – undo
28 28
 
29 29
     public function build()
30 30
     {
31
-        $fighters = $this->groupsByRound->first()->map(function ($item) {
31
+        $fighters = $this->groupsByRound->first()->map(function($item) {
32 32
             $fighters = $item->getFightersWithBye();
33 33
             $fighter1 = $fighters->get(0);
34 34
             $fighter2 = $fighters->get(1);
@@ -137,7 +137,7 @@  discard block
 block discarded – undo
137 137
             //The minus 3 is to ignore the final, semi final and quarter final rounds
138 138
 
139 139
             for ($i = 0; $i < $noRounds - 3; $i++) {
140
-                $tempRounds[] = 'Last '.$noTeamsInFirstRound;
140
+                $tempRounds[] = 'Last ' . $noTeamsInFirstRound;
141 141
                 $noTeamsInFirstRound /= 2;
142 142
             }
143 143
 
@@ -159,7 +159,7 @@  discard block
 block discarded – undo
159 159
         foreach ($roundTitles as $key => $roundTitle) {
160 160
             $left = $key * ($this->matchWrapperWidth + $this->roundSpacing - 1);
161 161
 
162
-            echo '<div class="round-title" style="left: '.$left.'px;">'.$roundTitle.'</div>';
162
+            echo '<div class="round-title" style="left: ' . $left . 'px;">' . $roundTitle . '</div>';
163 163
         }
164 164
         echo '</div>';
165 165
     }
@@ -172,7 +172,7 @@  discard block
 block discarded – undo
172 172
     public function getPlayerList($selected)
173 173
     {
174 174
         $html = '<select>
175
-                <option'.($selected == '' ? ' selected' : '').'></option>';
175
+                <option'.($selected == '' ? ' selected' : '') . '></option>';
176 176
 
177 177
         foreach ($this->championship->fighters as $fighter) {
178 178
             $html = $this->addOptionToSelect($selected, $fighter, $html);
@@ -232,7 +232,7 @@  discard block
 block discarded – undo
232 232
     {
233 233
         if ($fighter != null) {
234 234
             $select = $selected != null && $selected->id == $fighter->id ? ' selected' : '';
235
-            $html .= '<option'.$select
235
+            $html .= '<option' . $select
236 236
                 .' value='
237 237
                 .($fighter->id ?? '')
238 238
                 .'>'
Please login to merge, or discard this patch.