|
|
|
|
@ -229,14 +229,10 @@ final class MatchScheduler : ModelObject, Storable { |
|
|
|
|
return teamsAvailable |
|
|
|
|
})) |
|
|
|
|
|
|
|
|
|
if rotationIndex > 0 { |
|
|
|
|
if rotationIndex > 0, simultaneousStart == false { |
|
|
|
|
rotationMatches = rotationMatches.sorted(by: { |
|
|
|
|
if counts[$0.groupStageObject!.index] ?? 0 == counts[$1.groupStageObject!.index] ?? 0 { |
|
|
|
|
if simultaneousStart { |
|
|
|
|
return $0.groupStageObject!.orderedIndexOfMatch($0) < $1.groupStageObject!.orderedIndexOfMatch($1) |
|
|
|
|
} else { |
|
|
|
|
return $0.groupStageObject!.index < $1.groupStageObject!.index |
|
|
|
|
} |
|
|
|
|
} else { |
|
|
|
|
return counts[$0.groupStageObject!.index] ?? 0 < counts[$1.groupStageObject!.index] ?? 0 |
|
|
|
|
} |
|
|
|
|
|