April 10 (UPI) -- A federal judge has again ordered the Pentagon to restore access to credentialed journalists, ruling the Trump administration was attempting to flout his previous order by disguising it as an interim rule.

"The Department cannot simply reinstate an unlawful policy under the guise of taking 'new' action and expect the court to look the other way," U.S. District Judge Paul Friedman said in his Thursday ruling, obtained by Courthouse News.

The Department of Defense has said it intends to appeal.

The ruling comes in a case filed by The New York Times challenging a policy instituted by the Department of Defense in October requiring all journalists with access to the Pentagon to sign a form acknowledging they could have their credentials revoked for collecting unauthorized information.

Most Pentagon reporters declined and surrendered their credentials.