Skip to content

Commit

Permalink
update score when current >= best score
Browse files Browse the repository at this point in the history
  • Loading branch information
jongwooha98 committed Dec 16, 2021
1 parent f8c4ff7 commit 48dffa7
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/pages/Game2048/Game/Game.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -348,7 +348,7 @@ export const Game: React.FC = () => {
board: boardByValue,
score: currentScore,
});
if (currentScore > myBestScore) {
if (currentScore >= myBestScore) {
updateMyBestScore({ score: currentScore, gameType: gameType });
}
return;
Expand Down

0 comments on commit 48dffa7

Please sign in to comment.