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 70f6a77 commit 7ff5c29Copy full SHA for 7ff5c29
hwproj.front/src/components/Homeworks/CourseHomeworkExperimental.tsx
@@ -233,14 +233,14 @@ const CourseHomeworkEditor: FC<{
233
isDeadlineStrict: metadata.isDeadlineStrict,
234
publicationDate: metadata.publicationDate,
235
actionOptions: editOptions,
236
- tasks: homework.tasks!.map(t => {
+ tasks: isNewHomework ? homework.tasks!.map(t => {
237
const task: CreateTaskViewModel = {
238
...t,
239
title: t.title!,
240
maxRating: t.maxRating!
241
}
242
return task
243
- })
+ }) : []
244
245
246
const updatedHomework = isNewHomework
0 commit comments