Skip to content

Commit ebbfe87

Browse files
committed
Make sure all |s are escaped when converting question id
1 parent b663b97 commit ebbfe87

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/app/components/content/IsaacClozeQuestion.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -99,7 +99,7 @@ export function IsaacClozeQuestion({doc, questionId, readonly}: {doc: IsaacCloze
9999
const pageQuestions = useSelector(selectors.questions.getQuestions);
100100
const questionPart = selectQuestionPart(pageQuestions, questionId);
101101
const currentAttempt = questionPart?.currentAttempt as (ItemChoiceDTO | undefined);
102-
const cssFriendlyQuestionPartId = questionPart?.id?.replace("|", "-") ?? ""; // Maybe we should clean up IDs more?
102+
const cssFriendlyQuestionPartId = questionPart?.id?.replaceAll("|", "-") ?? ""; // Maybe we should clean up IDs more?
103103
const questionContentRef = useRef<HTMLDivElement>(null);
104104
const withReplacement = doc.withReplacement ?? false;
105105

0 commit comments

Comments
 (0)