projects
/
vchess.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
| inline |
side by side
Fix clocks while playing live game
[vchess.git]
/
client
/
src
/
utils
/
gameStorage.js
diff --git
a/client/src/utils/gameStorage.js
b/client/src/utils/gameStorage.js
index
3bd9934
..
77acf94
100644
(file)
--- a/
client/src/utils/gameStorage.js
+++ b/
client/src/utils/gameStorage.js
@@
-75,8
+75,7
@@
export const GameStorage =
{
game.moves.push(obj.move);
game.fen = obj.fen;
- if (!!obj.addTime) //NaN if first move in game
- game.clocks[obj.colorIdx] += obj.addTime;
+ game.clocks[obj.colorIdx] += obj.addTime;
game.initime[obj.nextIdx] = Date.now();
}
if (!!obj.score)