Update: President Trump has weighed in over Twitter, writing that he was "not pleased" with how Gallagher's trial was handled and that Spencer had been terminated. He also cited "large cost overruns from past administration's contracting procedures," adding "Eddie will retire peacefully with all of the honors that he has earned, including his Trident pin." :

....contracting procedures were not addressed to my satisfaction. Therefore, Secretary of the Navy Richard Spencer’s services have been terminated by Secretary of Defense Mark Esper. I thank Richard for his service & commitment. Eddie will retire peacefully with all of the..... — Donald J. Trump (@realDonaldTrump) November 24, 2019

....contracting procedures were not addressed to my satisfaction. Therefore, Secretary of the Navy Richard Spencer’s services have been terminated by Secretary of Defense Mark Esper. I thank Richard for his service & commitment. Eddie will retire peacefully with all of the..... — Donald J. Trump (@realDonaldTrump) November 24, 2019

***

Secretary of Defense Mark Esper asked Navy Secretary Richard Spencer to resign on Sunday after the Pentagon chief lost confidence in how Spencer handled the case of a Navy SEAL accused of war crimes in Iraq, according to the Pentagon.

President Trump sits next to former Navy Secretary Richard V. Spencer in July

Spencer's resignation stems from the controversial case of Chief Petty Officer Edward Gallagher, a Navy SEAL who was accused of war crimes during a 2017 deployment and later acquitted of murder. He was convicted in July of posing with the corpse of a captive, according to the Washington Post.

Esper asked for Spencer’s resignation after learning that he had privately proposed to White House officials that if they did not interfere with proceedings against Gallagher, then Spencer would ensure that Gallagher was able to retire as a Navy SEAL, with his Trident insignia. Spencer’s private proposal to the White House — which he did not share with Esper over the course of several conversations about the matter — contradicted his public position on the Gallagher case, chief Pentagon spokesman Jonathan Hoffman said in a statement. -Washington Post

Esper said that he was "deeply troubled by this conduct."

"Unfortunately, as a result I have determined that Secretary Spencer no longer has my confidence to continue in his position," Esper added in a statement. "I wish Richard well."

Spencer made his 'indecent' proposal to the White House after Trump intervened in the cases of Gallagher and two other soldiers on November 15 against Pentagon advice. He also issued pardons to Army Maj. Mathew Golsteyn, who faced a murder trial next year, and former 1st Lt. Clint Lorance, who was convicted in 2013 in the murder of two unarmed men in Afghanistan.

Notably Gallagher's legal team included Trump's personal attorney, Marc Mukasey as well as former New York City police commissioner Bernard Kerik, who served a brief stint with Iraq's Coalition Provisional Authority following the 2003 invasion.

Trump reinstated Gallagher's rank after he was demoted for posing with the corpse, which Esper agreed with.

"The Navy will NOT be taking away Warfighter and Navy Seal Eddie Gallagher’s Trident Pin," Trump tweeted last week. "This case was handled very badly from the beginning. Get back to business!"

The Navy will NOT be taking away Warfighter and Navy Seal Eddie Gallagher’s Trident Pin. This case was handled very badly from the beginning. Get back to business! — Donald J. Trump (@realDonaldTrump) November 21, 2019

Following Trump's tweet, the Navy was given White House guidance on November 22 that it would be allowed to proceed as planned according to an anonymous Navy official. According to the Epoch Times, however, "This would seem to have defused a conflict between the president and Navy leaders. Navy Secretary Richard Spencer said Nov. 23 at an international security forum in Halifax, Nova Scotia, that he didn’t consider a tweet by Trump an order. He said he would need a formal order to stop the Navy review board, scheduled to begin Dec. 2, that would determine whether Gallagher is allowed to remain in the SEALs."

"I need a formal order to act," Spencer said.

And now, he's been formally fired.