Skip to content

Commit

Permalink
fix limit feature
Browse files Browse the repository at this point in the history
  • Loading branch information
bbrk24 committed Jun 13, 2024
1 parent 08106a3 commit 08da4e6
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions src/index.civet
Original file line number Diff line number Diff line change
Expand Up @@ -255,9 +255,9 @@ installLimitListener := (name: 'characters' | 'karts' | 'wheels' | 'gliders') =>

currMenu = name
// @ts-ignore shut up
totalNames: string[] := data[name].flatMap &[name]
totalNames: string[] := currData[name].flatMap &[name]
// @ts-ignore shut up
indices := data[name].flatMap (el, i) => Array<number>(el[name].#).fill i
indices := currData[name].flatMap (el, i) => Array<number>(el[name].#).fill i
// @ts-ignore shut up
includedNames: string[] := limitedData[name].flatMap &[name]

Expand All @@ -272,7 +272,7 @@ installLimitListener := (name: 'characters' | 'karts' | 'wheels' | 'gliders') =>
menu.querySelectorAll<HTMLInputElement> 'input[type="checkbox"]'
.forEach .checked = true
// @ts-ignore It's just not correlating the LHS (&) with the RHS (|)
limitedData[name] = structuredClone data[name]
limitedData[name] = structuredClone currData[name]
selectedCount = total
else
menu.querySelectorAll<HTMLInputElement> 'input[type="checkbox"]'
Expand Down

0 comments on commit 08da4e6

Please sign in to comment.