Skip to content

Commit

Permalink
rename vars
Browse files Browse the repository at this point in the history
  • Loading branch information
inker committed Jan 15, 2024
1 parent aea7d1e commit 56657d6
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 6 deletions.
6 changes: 3 additions & 3 deletions src/pages/cl/ko/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -123,9 +123,9 @@ function CLKO({ season, pots: initialPots }: Props) {
)

const handleBallPick = useCallback(
async (i: number) => {
async (index: number) => {
const currentPot = potsToDisplay[currentPotNum]!
const pickedTeam = currentPot[i]
const pickedTeam = currentPot[index]

const newPots = pots.with(
currentPotNum,
Expand All @@ -145,7 +145,7 @@ function CLKO({ season, pots: initialPots }: Props) {
: null

const gwPot = newPossiblePairings
? newPots[0].filter((_, j) => newPossiblePairings.includes(j))
? newPots[0].filter((_, i) => newPossiblePairings.includes(i))
: null
const newPotsToDisplay = [gwPot, pots[1]] as const

Expand Down
6 changes: 3 additions & 3 deletions src/pages/el/ko/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -128,9 +128,9 @@ function ELKO({ season, pots: initialPots }: Props) {
)

const handleBallPick = useCallback(
async (i: number) => {
async (index: number) => {
const currentPot = potsToDisplay[currentPotNum]!
const pickedTeam = currentPot[i]
const pickedTeam = currentPot[index]

const newPots = pots.with(
currentPotNum,
Expand All @@ -150,7 +150,7 @@ function ELKO({ season, pots: initialPots }: Props) {
: null

const gwPot = newPossiblePairings
? newPots[0].filter((_, j) => newPossiblePairings.includes(j))
? newPots[0].filter((_, i) => newPossiblePairings.includes(i))
: null
const newPotsToDisplay = [gwPot, pots[1]] as const

Expand Down

0 comments on commit 56657d6

Please sign in to comment.