Skip to content

Commit

Permalink
fix: Error when user clicks several times on continue button.
Browse files Browse the repository at this point in the history
  • Loading branch information
UvgenGen committed Jul 5, 2021
1 parent ca23071 commit 2edc8af
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions src/data/thunks.js
Original file line number Diff line number Diff line change
Expand Up @@ -243,12 +243,12 @@ export function stopExam() {
}

await updateAttemptAfter(
exam.course_id, exam.content_id, stopAttempt(attemptId), true,
exam.course_id, exam.content_id, stopAttempt(attemptId),
)(dispatch);
};
}

export function continueExam(noLoading = true) {
export function continueExam() {
return async (dispatch, getState) => {
const { exam } = getState().examState;
const attemptId = exam.attempt.attempt_id;
Expand All @@ -261,7 +261,7 @@ export function continueExam(noLoading = true) {
return;
}
await updateAttemptAfter(
exam.course_id, exam.content_id, continueAttempt(attemptId), noLoading,
exam.course_id, exam.content_id, continueAttempt(attemptId),
)(dispatch);
};
}
Expand Down

0 comments on commit 2edc8af

Please sign in to comment.