From fa845fb7dd6cd99fa8196f58599f0c70679c4ec3 Mon Sep 17 00:00:00 2001 From: Ross Date: Sun, 18 Apr 2021 09:59:23 +0100 Subject: [PATCH] store question_id as int in db --- js/main.js | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/js/main.js b/js/main.js index cf03fb4..b6d6ca5 100644 --- a/js/main.js +++ b/js/main.js @@ -246,7 +246,7 @@ async function loadExamList(data) { for (let q in question_timestamp_hash) { let new_timestamp = question_timestamp_hash[q]; - q = q.toString(); + //q = q.toString(); $("#cache-details ul").append( `
  • Question (${saved_exam.exam_type}): ${q}` ); @@ -854,7 +854,7 @@ async function loadQuestion(n, section = 1, force_reload = false) { const qid = exam_details.question_order[n]; - let q = { qid: qid.toString(), type: question_type }; + let q = { qid: qid, type: question_type }; let return_data = await question_db.question_data.get(q); const question_data = return_data.data;