Fix corr games 'auto-lost-on-time'
authorBenjamin Auder <benjamin.auder@somewhere>
Wed, 10 Feb 2021 11:28:04 +0000 (12:28 +0100)
committerBenjamin Auder <benjamin.auder@somewhere>
Wed, 10 Feb 2021 11:28:04 +0000 (12:28 +0100)
server/models/Game.js

index 76a91dc..7f10b65 100644 (file)
@@ -510,6 +510,7 @@ const GameModel = {
             }
             // Set score if lost on time and >= 2 moves:
             else if (
+              g.score == '*' &&
               !!movesGroups[g.id] &&
               movesGroups[g.id].nbMoves >= 2 &&
               tsNow - movesGroups[g.id].lastMaj >