A Denver County judge ruled Friday that the city’s controversial urban camping ban is unconstitutional, amounting to cruel and unusual punishment.

In his ruling, Judge Johnny C. Barajas cited a decision from the 9th U.S. Circuit Court of Appeals striking down a camping ban in Boise, Idaho, last year. The U.S. Supreme Court recently declined to review that ruling.

Barajas granted Jerry Burton’s motion to dismiss a ticket he received this year for violating Denver’s camping ban at a site commonly known as Jerr-E-ville.

The judge quoted 9th Circuit Judge Marsha Berzon’s ruling in his decision: “As long as there is no option of sleeping indoors, the government cannot criminalize indigent, homeless people for sleeping outdoors, on public property, on the false premise they had a choice in the matter.”

Andy McNulty, Burton’s attorney, said Friday he hoped the ruling would prompt the Denver Police Department to “stop wasting resources on laws that are clearly unconstitutional and instead divert those resources to evidence-based solutions to homelessness.”

The City Attorney’s Office, however, indicated Denver will continue to defend the law. City officials have noted that the city’s shelters have open beds most nights, but the judge wrote that shelter curfews and other restrictions limit access for some people.

“We disagree with the ruling and plan to appeal to District Court,” spokesperson Ryan Luby said.

Denver Homeless Out Loud, which advocates for people experiencing homelessness, hailed the decision.

“Human beings cannot be forced into shelter like jail, and this ruling shows any reasonable person can understand the mere existence of a space in a shelter does not make that a viable or livable option for someone to be,” the organization said in a press release. “Hence criminalizing people for being poor with no home and surviving on the streets is cruel and unconstitutional.”

Homeless Out Loud renewed its recent call for the Denver City Council to repeal the camping ban.

Denver has banned unauthorized camping on public and private property since 2012, though citations and arrests are rare. Street checks and police contact with unauthorized campers are not, however. Voters rejected a measure in May, Initiative 300, that would have overturned the camping ban.

The Ninth Circuit was the fourth U.S. appeals court to rule against urban camping bans. The decision had no direct impact on Denver because it falls under the jurisdiction of the Tenth U.S. Circuit Court of Appeals, which isn’t one of the four.