WASHINGTON (CN) – The White House is bristling Wednesday after a federal judge reinstated press access to a Playboy reporter whose clash with a former adviser to the president went viral this summer.

“We disagree with the decision of the district court to issue an injunction that essentially gives free reign to members of the press to engage in unprofessional, disruptive conduct at the White House,” White House Press Secretary Stephanie Grisham said in a statement.

U.S. District Judge Rudolph Contreras issued the injunction Tuesday night in a 24-page opinion, saying the White House did not clearly outline the circumstances under which a reporter might lose his press badge.

This left Playboy reporter Brian Karem unaware that his press pass would be suspended when he got involved in a shouting match with former Trump assistant Sebastian Gorka after a Rose Garden press conference in July, Contreras found.

“As the court will explain below, Karem has, at this early stage of the proceedings, shown that he is likely to succeed on this due process claim, because the present record indicates that Stephanie Grisham failed to provide fair notice of the fact that a hard pass could be suspended under these circumstances,” Contreras wrote.

After Karem tried to ask Trump a question following a press conference in the Rose Garden on July 11, the audience, primarily made up of prominent online Trump supporters, began mocking him. Karem responded with a quip, gesturing to the crowd and saying “this is a group eager for demonic possession.”

Gorka did not see the humor and started shouting at Karem from across the Rose Garden. He eventually marched across the space, getting in Karem’s face and calling him a “punk.” Karem shouted to Gorka to “get a job” and offered to talk with him outside, which the White House says was a challenge to a fight.

Based on the incident, the White House suspended Karem’s press credentials for 30 days.

Karem filed suit in the U.S. District Court for the District of Columbia, seeking to have his badge restored on the grounds that the White House did not have a clear standard for professional conduct before the Rose Garden incident.

Contreras agreed with this, saying a letter the White House sent to CNN correspondent Jim Acosta detailing expected behavior during press conferences was ambiguous and creates an “unnecessarily vague” standard for reporters to follow.

“What is deemed ‘professional’ behavior in the context of a state dinner may be very different from what is considered ‘professional’ behavior during a performance by James Brown,” Contreras wrote.

Contreras found Karem would be irreparably harmed without access to the White House, which is necessary to do his work, and that the his interests outweigh those of the White House.

In a statement, Ted Boutrous, an attorney with the firm Gibson, Dunn & Crutcher who represented Karem, said the White House was trying to “chill vigorous reporting about the president” when it pulled Karem’s pass.

Grisham decried the ruling, saying Karem’s actions in the Rose Garden “clearly breached well-understood norms of professional conduct.”