From 4a108aef06a6e0ebdfe201fe8c88b63dfe290320 Mon Sep 17 00:00:00 2001 From: Fabian Stamm Date: Wed, 11 Sep 2019 17:51:54 +0200 Subject: [PATCH] asd --- src/stores.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/stores.ts b/src/stores.ts index bab7dad..7143cba 100644 --- a/src/stores.ts +++ b/src/stores.ts @@ -47,7 +47,7 @@ class QuestionManager { if (options.length <= 0) options = this.availableQuestions; - let idx = Math.random() * options.length; + let idx = Math.floor(Math.random() * options.length); let randomItem = options[idx]; console.log("Setting question", randomItem); this.activeQuestion.set({