It was a bad day to be a lawyer in Tanya S. Chutkan‘s courtroom on Monday. The U.S. District Court judge chewed out both sides of the Mariia “Maria” Butina case, but it was pretty embarrassing for the prosecution, who has just walked back their claims that the defendant traded sex for access.

She said she reviewed the messages between Butina and Republican operative Paul Erickson. It took her about five minutes to look over them and tell they were jokes, she said, according to The Washington Post.

Could’ve been worse, though. Chutkan applauded the prosecution for admitting their mistake in a Friday court filing, though she cautioned the U.S. Attorneys that, “It could make it difficult to have a fair trail when these mistakes are made.” She said it “dismayed” her that anyone at the DOJ or U.S. Attorney’s office could review those messages and think they were serious.

And that’s not to say that defense got everything they wanted either. Chutkin chastised Butina’s lawyer Robert N. Discoll for “going all over the networks” talking about the case. Accordingly, she imposed a gag order.

The judge also agreed that Butina, a Russian national, was a flight risk. The defendant will remain in jail pending trial.

Even when walking back their sex allegation on Friday, prosecutors continue to insist that her ties to Erickson weren’t strong enough to guarantee she’d appear in court again if released.

Prosecutors say she was an unregistered agent of the Russian government, gaining access to U.S. organizations to influence national politics.

Note: Fixed typo.

[Image via Alexandria Detention Center]

Have a tip we should know? [email protected]