Can we only do this in the case when the student has completed less than the required number?  So add a already_completed.count() < self.required_count() .