diff --git a/src/infrastructure/api/converters/registeredCourse.ts b/src/infrastructure/api/converters/registeredCourse.ts index 902d7525..2487ffea 100644 --- a/src/infrastructure/api/converters/registeredCourse.ts +++ b/src/infrastructure/api/converters/registeredCourse.ts @@ -60,8 +60,12 @@ const updateApiCourseProp = < v2: Required[P] ) => boolean ): void => { - if (apiCourse.course && compareFn(apiCourse.course[prop], newValue)) return; - apiCourse[prop] = newValue; + if ( + prop in apiCourse || + (apiCourse.course && !compareFn(apiCourse.course[prop], newValue)) + ) { + apiCourse[prop] = newValue; + } }; /**