}
enrolment.setUsedInSeparationCycle(true);
if (enrolment.isOptional()) {
final OptionalEnrolment optional = (OptionalEnrolment) enrolment;
if (parent.hasChildDegreeModule(optional.getOptionalCurricularCourse())) {
return;
}
final Substitution substitution = createSubstitution(enrolment, parent);
createNewOptionalDismissal(substitution, parent, enrolment, optional.getOptionalCurricularCourse(),
optional.getEctsCredits());
} else {
createNewDismissal(createSubstitution(enrolment, parent), parent, enrolment);
}
}