Skip to content

Commit

Permalink
Online Student Scheduling: Enroll (Hiberante 6.6 Fix)
Browse files Browse the repository at this point in the history
- fixed a Hibernate error: persistent instance references an unsaved transient instance of CourseDemand
  - thrown when dropping a course demand that was wait-listed in the past
  - likely caused by Student.resetWaitLists(..) touching previuous WaitList records that refer the course demand that was just deleted
  • Loading branch information
tomas-muller committed Jan 24, 2025
1 parent 5c51a12 commit 0c65bba
Showing 1 changed file with 1 addition and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -784,6 +784,7 @@ else if (!courseId.equals(ca.getCourseId())) {
helper.getHibSession().merge(student);

if (wlMode == WaitListMode.WaitList) {
helper.getHibSession().flush();
student.resetWaitLists(
WaitList.WaitListType.SCHEDULING_ASSISTANT,
helper.getUser().getExternalId(),
Expand Down

0 comments on commit 0c65bba

Please sign in to comment.