diff --git a/eduaid_web/package-lock.json b/eduaid_web/package-lock.json index 265257c..51e19bd 100644 --- a/eduaid_web/package-lock.json +++ b/eduaid_web/package-lock.json @@ -16,7 +16,7 @@ "react-dom": "^18.3.1", "react-icons": "^5.2.1", "react-router-dom": "^6.26.0", - "react-scripts": "5.0.1", + "react-scripts": "^5.0.1", "react-switch": "^7.0.0", "web-vitals": "^2.1.4" }, diff --git a/eduaid_web/src/pages/Output.jsx b/eduaid_web/src/pages/Output.jsx index e1b2424..7004448 100644 --- a/eduaid_web/src/pages/Output.jsx +++ b/eduaid_web/src/pages/Output.jsx @@ -60,12 +60,8 @@ const Output = () => { if (questionType === "get_mcq") { qaPairsFromStorage["output"].forEach((qaPair) => { - const options = qaPair.answer - .filter((ans) => !ans.correct) - .map((ans) => ans.answer); - const correctAnswer = qaPair.answer.find( - (ans) => ans.correct - )?.answer; + const options = qaPair.options; + const correctAnswer = qaPair.answer; combinedQaPairs.push({ question: qaPair.question,