The Pea Ridge School District in Arkansas violated the Americans with Disabilities Act when it removed three students until they were tested for HIV, according to a letter from the U.S. Department of Justice’s civil rights division.

The Northwest Arkansas Democrat-Gazette reports that in 2013 the school district had excluded the students, who were foster children, after it received documents about the HIV status of one of their family members. But that was illegal, as the Department of Justice’s letter explained, because “a student’s HIV status, actual or perceived, is not a permissible basis for the exclusion of a student from a public school setting.”

The district wanted the children tested for HIV before they returned to the classroom, but they were allowed back four days after their ouster and before the test results were in.

The school district claims it took those actions based on the advice of its attorney at the time, who said he feared other students and staff could be exposed to the virus.

In its letter, the Department of Justice listed ways the school district could address its violations, including revising its policy on communicable diseases.