Skip to content

Commit

Permalink
app components player: fix max score when you're winning
Browse files Browse the repository at this point in the history
  • Loading branch information
cmnord committed Aug 11, 2023
1 parent 79a9c56 commit 8129e44
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion app/components/player/player.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -67,7 +67,7 @@ export function PlayerScores({ userId }: { userId: string }) {
.sort((a, b) => b.score - a.score);

const maxScore = sortedOtherPlayers[0]
? sortedOtherPlayers[0].score
? Math.max(sortedOtherPlayers[0].score, yourPlayer.score)
: yourPlayer.score;

return (
Expand Down

1 comment on commit 8129e44

@vercel
Copy link

@vercel vercel bot commented on 8129e44 Aug 11, 2023

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Please sign in to comment.