A state appellate court has overturned the suspension of a University of California, Santa Barbara student who was barred from campus and classes for two years after a school disciplinary committee found that he sexually assaulted another student.

The Second District Court of Appeal on Tuesday found that the suspended student, referred to as John Doe in court papers, was denied access to a critical report made by the Santa Barbara County Sexual Assault Response Team about his accuser’s medical examination and was therefore denied the opportunity to adequately cross-examine witnesses. The court also found that the university’s review process denied Doe the opportunity to present defense evidence, and that he wasn’t provided a fair hearing by the two-member university committee which reviewed his case.