In the unanimous decision released Thursday, Illinois’ highest court found the statute violates the free speech and due process protections of the U.S. and Illinois constitutions.

The 1961 Illinois Eavesdropping Act made it a felony for someone to produce an audio recording of a conversation unless all parties agree.

But the court found the statute, as written, was far too broad. Among other findings, the court says it criminalizes recordings that are clearly public.

The central figure in the ruling is Annabel Melongo. She was charged under the law in 2010 for recording a Cook County court official. She spent more than a year in jail awaiting trial. The jury in her case couldn’t reach a verdict.