DENVER (AP) — A man who left a homemade bomb outside a police station in a Colorado mountain town could spend less time in prison under a U.S. appeals court decision in the case.

David Ansberry was sentenced last year to 27 years in prison for leaving the device, which did not explode, outside the Nederland police station in 2016. He pleaded guilty to attempting to use a weapon of mass destruction against a person or property.

His sentence was lengthened because a judge found that his actions were an act of terrorism and that the police officer who picked up the bag that contained the bomb was also a victim of the crime.

In a 2-1 ruling Wednesday, a three-judge panel of the 10th Circuit Court of Appeals threw out the two findings by the judge that had lengthened the sentence and ordered a lower court to re-sentence Ansberry.

U.S. District Judge Christine Arguello determined that Ansberry was seeking revenge for the town marshal’s killing of a fellow member of a band of hippies in 1971 after arresting him. However, the appeals court panel said a terrorism sentencing enhancement can only be given if the crime is determined to be in response to what is actually official government conduct.

The ruling said Arguello could still decide to re-impose a terrorism sentence enhancer if she determined the shooting was government conduct.

The panel also found that treating the police officer as a victim went beyond the scope of what Ansberry admitted to doing when he pleaded guilty.

The judges unanimously rejected Ansberry's argument that he did not create a risk of serious bodily injury because the bomb was small and because he tried to detonate it when the parking lot was empty before dawn.

Federal prosecutors are allowed to ask for a hearing before the full appeals court or appeal the decision to the U.S. Supreme Court.

A spokesperson for the U.S. Attorney's Office, Jeff Dorschner, said the office was reviewing its options but declined further comment on Friday.

One of Ansberry's lawyers, Abe Hutt, declined to comment on the ruling at this point because he said he and his co-counsel were still reviewing the decision and its implications.

During sentencing, Ansberry's lawyers argued he should only serve about two years in prison — the time he had already spent behind bars at the time.

Copyright 2020 The Associated Press. All rights reserved. This material may not be published, broadcast, rewritten or redistributed without permission.