Skip to content

Commit

Permalink
fix: handle case of solve before joining
Browse files Browse the repository at this point in the history
For some reason, typescript did not catch this type error.
  • Loading branch information
r2dev2 committed Jul 22, 2024
1 parent 987e874 commit a9795a5
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/js/store.js
Original file line number Diff line number Diff line change
Expand Up @@ -64,7 +64,7 @@ export const timeTakenByOpponents = derived(
$users.map((u) => [
u.id,
u.solved
? get(timeTakenByOpponents).get(u.id) ?? Date.now() - $problemStart
? get(timeTakenByOpponents)?.get(u.id) ?? Date.now() - $problemStart
: Date.now() - $problemStart,
])
);
Expand Down

0 comments on commit a9795a5

Please sign in to comment.