MDL-41417 course: allow the use of a duplidate idnumbers if they were duplicated before fix