Skip to content

Commit 4c1d42f

Browse files
TD-5291 Issue on 'Course set up' screen when selected Few course content first time and changed to 'All' of them clicking 'change link'
1 parent 409b1ee commit 4c1d42f

File tree

1 file changed

+3
-0
lines changed

1 file changed

+3
-0
lines changed

DigitalLearningSolutions.Web/Controllers/TrackingSystem/CourseSetup/CourseSetupController.cs

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -662,10 +662,13 @@ private IActionResult SaveSectionAndRedirect(SetSectionContentViewModel model)
662662
sectionsToRemove.Add(section);
663663
}
664664
}
665+
if (sectionsToRemove.Count > 0)
666+
{
665667
foreach (var section in sectionsToRemove)
666668
{
667669
data.SectionContentData.Remove(section);
668670
}
671+
}
669672
data!.SectionContentData!.Add(
670673
new SectionContentTempData(
671674
model.Tutorials != null

0 commit comments

Comments
 (0)