Commented existed possible answers checking

This commit is contained in:
mrfry 2021-03-30 11:25:35 +02:00
parent faefca9b55
commit 7e70aa6c8e

View file

@ -1012,23 +1012,24 @@ function GetApp(): ModuleType {
const savedQuestions = utils.ReadJSON(savedSubjQuestionsFilePath)
const testExists = false
// TODO: do this on another thread?
const testExists = savedQuestions.some((savedQuestion) => {
const data = utils.ReadJSON(`${subjPath}/${savedQuestion.fname}`)
// const testExists = savedQuestions.some((savedQuestion) => {
// const data = utils.ReadJSON(`${subjPath}/${savedQuestion.fname}`)
return data.questions.some((dQuestion) => {
return questions.some((question) => {
const percent = compareQuestionObj(
createQuestion(question),
'',
createQuestion(dQuestion),
''
)
// return data.questions.some((dQuestion) => {
// return questions.some((question) => {
// const percent = compareQuestionObj(
// createQuestion(question),
// '',
// createQuestion(dQuestion),
// ''
// )
return percent.avg === 100
})
})
})
// return percent.avg === 100
// })
// })
// })
if (testExists) {
return