WASHINGTON — A federal judge has dismissed porn actress Stormy Daniels' defamation lawsuit against President Trump. U.S. District Judge S. James Otero issued the order Monday in Los Angeles.

Daniels, whose real name is Stephanie Clifford, alleges she had an affair with Mr. Trump in 2006 and sued him in April after he said a composite sketch of a man she said threatened her in 2011 to keep quiet about an alleged affair with the real estate mogul was a "con job."

In dismissing the suit, the judge said Mr. Trump's tweet was a "hyperbolic statement" against a political adversary.

Get Breaking News Delivered to Your Inbox

Mr. Trump's lawyer, Charles Harder, said it was a "total victory" for the president.

Stormy Daniels, accompanied by her attorney, Michael Avenatti, right, seen April 16, 2018, in New York. AP

"No amount of spin or commentary by Stormy Daniels or her lawyer ... can truthfully character today's ruling in any way other than total victory for President Trump and total defeat for Stormy Daniels," Harder said.

Harder said Mr. Trump is "entitled to an award of his attorneys' fees against Daniels."

Daniels' attorney, Michael Avenatti strongly disagreed in a tweet early Tuesday:

Below is a statement just issued relating to the litigation between Stormy Daniels and Donald Trump. pic.twitter.com/nm0xl99Z86 — Michael Avenatti (@MichaelAvenatti) October 16, 2018

Avenatti had already vowed to appeal and said he's confident the ruling will be reversed. Daniels' lawsuit over a $130,000 hush-money deal is pending.

In his ruling, Otero ruled that Mr. Trump's tweet was protected by freedom of speech.

"The Court agrees with Mr. Trump's argument because the tweet in question constitutes 'rhetorical hyperbole' normally associated with politics and public discourse in the United States. The First Amendment protects this type of rhetorical statement," Otero wrote.