PORTLAND, Ore. (AP) — A federal judge in Portland has ruled that a group of Oregon prison inmates can proceed with their lawsuit against state officials over their response to the coronavirus pandemic.

The class-action lawsuit says the seven inmates named in the case have underlying medical conditions and are at risk for contracting COVID-19, Oregon Public Broadcasting reported. The case applies to any Department of Corrections inmate who has been infected or is medically vulnerable.

U.S. Magistrate Judge Stacie Beckerman ruled this week that state leaders named in the lawsuit are not protected from litigation over their response to the pandemic inside Oregon’s correctional institutions.

The ruling is believed to be one of the first in which a judge found a state is not protected from litigation over its pandemic response in prisons and could have to pay financial damages.

The lawsuit names Gov. Kate Brown, Oregon Department of Corrections Director Collette Peters and other prison officials.

In August, the Oregon Department of Justice, which represents the state officials, asked Beckerman to dismiss the lawsuit’s primary argument. Their attorneys argued the defendants were protected by qualified immunity because the COVID-19 pandemic is unprecedented and there’s no clear constitutional requirement for the Department of Corrections to limit COVID-19 spread inside prisons.

Beckerman disagreed in a 26-page opinion.

“The law does not support a finding of qualified immunity for government officials who fail to protect individuals in their custody from a new serious communicable disease, as opposed to a serious communicable disease of which they were previously aware,” Beckerman wrote. “To hold otherwise as a matter of law would provide qualified immunity to defendants even if they had done nothing in response to the COVID-19 pandemic.”

The Oregon Department of Justice did not immediately respond to a request for comment. Brown’s office declined to comment, citing the pending litigation.

More than 1,670 people in state custody have contracted COVID-19 this year, and 19 have died as of Tuesday, according to the state.