Skip to content

Commit

Permalink
change pot order
Browse files Browse the repository at this point in the history
  • Loading branch information
inker committed Jul 3, 2024
1 parent c4cf187 commit 153c41a
Showing 1 changed file with 2 additions and 6 deletions.
8 changes: 2 additions & 6 deletions src/engine/dfs/ls/generatePairings/getFirstSuitableMatch.ts
Original file line number Diff line number Diff line change
Expand Up @@ -40,12 +40,8 @@ export default ({
boolean
> = {};

const potPairs = orderBy(cartesian(potIndices, potIndices), ([h, a]) => {
if (h === a) {
return h / 1000;
}
return h + a * 0.0001 + 1000;
});
const unorderedPotPairs = cartesian(potIndices, potIndices);
const potPairs = orderBy(unorderedPotPairs, [m => m[0], m => m[1]]);

for (const m of pickedMatches) {
const homeTeam = teams[m[0]];
Expand Down

0 comments on commit 153c41a

Please sign in to comment.