Code Duplication    Length = 4-4 lines in 2 locations

models/Match.php 2 locations

@@ 1404-1407 (lines=4) @@
1401
1402
            foreach ($matches as $i => &$match) {
1403
                // Reset teams' ELOs if they haven't been reset already
1404
                if ($match->getTeamA()->supportsMatchCount() && !isset($teamsReset[ $match->getTeamA()->getId() ])) {
1405
                    $teamsReset[ $match->getTeamA()->getId() ] = true;
1406
                    $match->getTeamA()->setElo($match->getTeamAEloOld());
1407
                }
1408
                if ($match->getTeamB()->supportsMatchCount() && !isset($teamsReset[ $match->getTeamB()->getId() ])) {
1409
                    $teamsReset[ $match->getTeamB()->getId() ] = true;
1410
                    $match->getTeamB()->setElo($match->getTeamBEloOld());
@@ 1408-1411 (lines=4) @@
1405
                    $teamsReset[ $match->getTeamA()->getId() ] = true;
1406
                    $match->getTeamA()->setElo($match->getTeamAEloOld());
1407
                }
1408
                if ($match->getTeamB()->supportsMatchCount() && !isset($teamsReset[ $match->getTeamB()->getId() ])) {
1409
                    $teamsReset[ $match->getTeamB()->getId() ] = true;
1410
                    $match->getTeamB()->setElo($match->getTeamBEloOld());
1411
                }
1412
1413
                $match->recalculateElo();
1414