lib/meibo/classroom_set.rb in meibo-0.25.3 vs lib/meibo/classroom_set.rb in meibo-0.26.0

- old
+ new

@@ -4,10 +4,12 @@ class ClassroomSet < DataSet def check_semantically_consistent super each do |classroom| - roster.organizations.find(classroom.school_sourced_id) + school = roster.organizations.find(classroom.school_sourced_id) + raise InvalidDataTypeError unless school.school? + roster.courses.find(classroom.course_sourced_id) raise DataNotFoundError, "termSourcedIdは1つ以上指定してください" if classroom.term_sourced_ids.empty? classroom.term_sourced_ids.each do |term_sourced_id|