diff options
-rw-r--r-- | admin/public/questions.js | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/admin/public/questions.js b/admin/public/questions.js index 32e48bf..ad0bc1a 100644 --- a/admin/public/questions.js +++ b/admin/public/questions.js @@ -52,6 +52,5 @@ function render(index) { document.getElementById("switch").addEventListener("click", () => { chart.destroy(); render(++question_index); - if (question_index + 1 < data.length) question_index++; - else question_index = 0; + if (question_index + 1 >= data.length) question_index = -1; }); |