feat: seperate single and multi choice questions
This commit is contained in:
@@ -28,7 +28,7 @@ export const checkAnswerCorrectness = (
|
||||
}
|
||||
}
|
||||
|
||||
if (question.type === QuestionType.MULTI_CHOICE) {
|
||||
if (question.type === QuestionType.SINGLE_CHOICE) {
|
||||
if (choiceId === undefined || choiceId === null) {
|
||||
throw new BadRequestException('submissions.errors.emptyChoiceId');
|
||||
}
|
||||
|
||||
@@ -18,7 +18,7 @@ export const getNextTransition = (
|
||||
);
|
||||
|
||||
if (
|
||||
question.type === QuestionType.MULTI_CHOICE &&
|
||||
question.type === QuestionType.SINGLE_CHOICE &&
|
||||
answerSubmissionDto.choiceId !== undefined
|
||||
) {
|
||||
const transition = transitions.find(
|
||||
|
||||
Reference in New Issue
Block a user