From 6b68ee08fb0cbb860316aaaa1ae6b6bba7bda64a Mon Sep 17 00:00:00 2001 From: "Steinar H. Gunderson" Date: Sun, 14 Dec 2014 11:52:46 +0100 Subject: [PATCH] Fix off-by-one in move history handling. --- www/js/book.js | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/www/js/book.js b/www/js/book.js index 47e540e..efb68e3 100644 --- a/www/js/book.js +++ b/www/js/book.js @@ -32,10 +32,10 @@ var update = function() { if (i % 2 == 0) { text += (i/2 + 1) + ". "; } - if (i == move_override) { + if (i + 1 == move_override) { text += '' + history[i] + ''; } else { - text += '' + history[i] + ''; + text += '' + history[i] + ''; } text += " "; } -- 2.39.2