WASHINGTON – President Donald Trump said Wednesday he is ordering the withdrawal of military awards for Navy attorneys who prosecuted former Navy SEAL Eddie Gallagher, saying they did an unfair job.

"Not only did they lose the case, they had difficulty with respect to information that may have been obtained from opposing lawyers and for giving immunity in a totally incompetent fashion," Trump tweeted.

Earlier this month, a jury found Gallagher not guilty of premeditated murder after being charged with killing a teenage Islamic State prisoner in Iraq.

As supporters protested the prosecution, Trump at one point ordered Gallagher released from solitary confinement.

Gallagher was convicted of improperly posing for a picture with the prisoner's body. He had displayed the photo at a re-enlistment ceremony and bragged that he "got this one with my knife."

Members of Gallagher's platoon made accusations against him last year.

The case became a cause célèbre for conservatives who argued that Gallagher was being unfairly targeted for actions in the war zone of Iraq.

Trump, who had spoken of pardoning Gallagher at one point, said Wednesday he recently learned that prosecutors in the case were to have received Navy Achievement Medals.

"I have directed the Secretary of the Navy Richard Spencer & Chief of Naval Operations John Richardson to immediately withdraw and rescind the awards," Trump said in a series of tweets.

He added: "I am very happy for Eddie Gallagher and his family."

Task & Purpose, a military and veteran-focused digital media company, reported Tuesday that "members of the U.S. government team that prosecuted him were awarded medals for their 'superb results' and 'expert litigation.'"