fix: lastTimePlayed not updating correctly when merging games

This commit is contained in:
Zamitto
2025-10-10 14:40:57 -03:00
parent a9b67ad1e6
commit 91fd5932da
2 changed files with 4 additions and 3 deletions

View File

@@ -22,7 +22,8 @@ export const mergeWithRemoteGames = async () => {
const updatedLastTimePlayed =
localGame.lastTimePlayed == null ||
(game.lastTimePlayed &&
new Date(game.lastTimePlayed) > localGame.lastTimePlayed)
new Date(game.lastTimePlayed) >
new Date(localGame.lastTimePlayed))
? game.lastTimePlayed
: localGame.lastTimePlayed;