A British law which had been used to prosecute a variety of poorly defined offenses will be amended, to the joy of British free speech advocates.

Chris Jackson/Getty Images Members of the public stroke a police horse in the Olympic Park during the London 2012 Paralympic Games, Sept. 1, 2012 in London, England.

Six years ago, an Oxford student named Sam Brown asked a mounted police officer a question: “Excuse me, do you realize your horse is gay?” Brown was arrested for making homophobic remarks. He refused to pay the fine and the prosecution dropped the case. The following year a 16-year old from Newcastle was charged under the same Public Order law, for saying “woof” to a dog in front of police officers.

(MORE: Poll: What Word Should Be Banished in 2013?)

Both were charged under Section 5 of Britain’s Public Order Act. The law, which covers both the spoken and written word, stated that a person could be found guilty of an offense if he or she used threatening, abusive or insulting words or behavior. But what was considered “insulting” was left to the discretion of the police and prosecutors, an aspect of the law that has drawn strong criticism from free-speech advocates.

This week, the House of Lords has agreed to amend the law so that “insulting” words or behavior will no longer be considered prosecutable offenses under Section 5. The Home Secretary announced that the government would accept changes to the act after receiving assurances “that the word ‘insulting’ could safely be removed without the risk of undermining the ability of the CPS [Crown Prosecution Service] to bring prosecutions.” It’s a change that free speech advocates are applauding.”This is a victory for free speech,” Simon Calvert, campaign director for the Reform Section 5 group, told the BBC. “People of all shades of opinion have suffered at the hands of Section 5. By accepting the Lords amendment to reform it, the government has managed to please the widest possible cross-section of society. They have done the right thing and we congratulate them.”

MORE: Pentagon Word$mithing…