Idaho Gov. Brad Little (R) vowed to fight a court decision Friday ruling that the state must provide a multi-thousand dollar gender reassignment surgery for a convicted sex offender.

The 9th Circuit Court of Appeals upheld U.S. District Judge B. Lynn Winmill’s ruling Friday regarding inmate Adree Edmo, who is serving a ten-year prison sentence for sexually abusing a 15-year-old boy when he was 22. Edmo was reportedly diagnosed with gender dysphoria and has tried to castrate himself twice.

“She suffers every single day while they have denied this treatment to her for years and there can be no reason justifying Idaho’s continued refusal to provide her care except bias,”  Edmo’s attorney Lori Rifkin said, according to Fox 13.

The court ruled that the state’s refusal to provide surgery violated the Eighth Amendment.

Per Fox 13:

In an 85-page opinion, the panel ruled that the state of Idaho must provide gender reassignment surgery to Edmo, writing that “responsible prison officials were deliberately indifferent to Edmo’s gender dysphoria, in violation of the Eighth Amendment.”

“Prison authorities have not provided that treatment despite full knowledge of Edmo’s ongoing and extreme suffering and medical needs,” the judges wrote.

“It is enough that [her doctor] knew of and disregarded an excessive risk to Edmo’s health by rejecting her request for [gender confirmation surgery] and then never re-evaluating his decision despite ongoing harm to Edmo,” the judges added, according to NPR:

Despite two other physicians agreeing with the original treatment plan, the ruling found that “general agreement in a medically unacceptable form of treatment does not somehow make it reasonable.”

The surgery, set to be organized by the Idaho Department of Correction and Corizon, will reportedly cost taxpayers between $20,000 and $30,000.

“Edmo would be reassigned to a women’s prison after the procedure, as per Idaho Department of Correction policy,” Fox 13 added.

Gov. Little vowed to fight against the ruling.

“We cannot divert critical public dollars away from the higher priorities of keeping the public safe and rehabilitating offenders,” Little said, according to NPR.

“The hardworking taxpayers of Idaho should not be forced to pay for a convicted sex offender’s gender reassignment surgery when it is contrary to the medical opinions of the treating physician and multiple mental health professionals,” he added.

According to Boise State Public Radio, Little signaled the state will appeal the ruling to the Supreme Court. It has 90 days to do so.