From: Laurent Mazet Date: Sun, 18 Oct 2020 18:49:12 +0000 (+0200) Subject: avoid error when currentPlayer is not set X-Git-Url: https://secure.softndesign.org/git/?a=commitdiff_plain;h=6c74d77a974f998474152393e1b5ec7655d99ce1;p=trivabble.git avoid error when currentPlayer is not set --- diff --git a/public/trivabble.js b/public/trivabble.js index 2100d7d..9a56fd0 100644 --- a/public/trivabble.js +++ b/public/trivabble.js @@ -1879,6 +1879,10 @@ myConfirm( _("Do you want to add score to active player?") + " " + totalScore, function () { + if (currentPlayer === "") { + return; + } + const scoreCell = tablePlayers[currentPlayer].childNodes[2].childNodes[0]; sendCmds([{ cmd: "score",