We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 81f8a24 commit 3bd16cfCopy full SHA for 3bd16cf
src/pages/instructor/grading.tsx
@@ -96,8 +96,10 @@ const InstructorGrading: PageWithLayout = () => {
96
// Remove graded submission from list
97
setSubmissions(submissions.filter((s) => s.id !== submissionId));
98
// Clear form data
99
- setScore({ ...score, [submissionId]: 0 });
100
- setFeedback({ ...feedback, [submissionId]: "" });
+ const { [submissionId]: _, ...remainingScores } = score;
+ setScore(remainingScores);
101
+ const { [submissionId]: __, ...remainingFeedback } = feedback;
102
+ setFeedback(remainingFeedback);
103
} else {
104
setError(data.error || "Failed to grade submission");
105
}
0 commit comments