From 47c55af132bbcf3093025a347537f30828ab66c2 Mon Sep 17 00:00:00 2001 From: Victor Giers Date: Thu, 8 Jan 2026 02:06:15 +0100 Subject: [PATCH] Remove unused useEffect hooks in QuizRunner.tsx --- client/src/components/QuizRunner.tsx | 26 -------------------------- 1 file changed, 26 deletions(-) diff --git a/client/src/components/QuizRunner.tsx b/client/src/components/QuizRunner.tsx index 453af15..3d9aa43 100644 --- a/client/src/components/QuizRunner.tsx +++ b/client/src/components/QuizRunner.tsx @@ -444,32 +444,6 @@ export default function QuizRunner({ defaultMode = 'all', defaultEntryId, autoSt const correctText = deriveCorrectText(currentQuestion); const shouldShowExplanation = showResult && (!lastCorrect || showExplanation); - useEffect(() => { - if (status !== 'running') return; - const saved = history[currentIndex]; - if (saved) { - setResponse(saved.response); - setShowResult(true); - setLastCorrect(saved.correct); - setLastSkipped(saved.skipped); - setShowExplanation(saved.showExplanation); - } else { - resetQuestionState(); - } - }, [currentIndex, history, status]); - - useEffect(() => { - if (!showResult) return; - setHistory((prev) => { - const next = [...prev]; - const existing = next[currentIndex]; - if (existing) { - next[currentIndex] = { ...existing, showExplanation }; - } - return next; - }); - }, [showExplanation, showResult, currentIndex]); - return (