U.S. President Donald Trump lashed out at Republican Sen. John McCain for suggesting that last week’s U.S. raid in Yemen, which resulted in the death of a Navy SEAL and killed a number of civilians, wasn’t a success.

Trump said in a series of early morning tweets Thursday that McCain “should not be talking about the success or failure of a mission to the media. Only emboldens the enemy!”

Sen. McCain should not be talking about the success or failure of a mission to the media. Only emboldens the enemy! He's been losing so…. — Donald J. Trump (@realDonaldTrump) February 9, 2017

..Ryan died on a winning mission ( according to General Mattis), not a "failure." Time for the U.S. to get smart and start winning again! — Donald J. Trump (@realDonaldTrump) February 9, 2017

He added that McCain has “been losing so long he doesn’t know how to win anymore, just look at the mess our country is in — bogged down in conflict all over the place.”

WATCH: Yemen raid planned by Obama administration, approved by Trump

3:34 Yemen raid planned by Obama administration, approved by Trump Yemen raid planned by Obama administration, approved by Trump

McCain said Wednesday that any operation where a $75-million airplane is lost, a Navy SEAL is killed, and there are multiple casualties, including women and children, ‘‘cannot be labelled a success.’’

Story continues below advertisement

“Every military operation has objectives. And while many of the objectives of the recent raid in Yemen were met, I would not describe any operation that results in the loss of American life as a success,” McCain said in a statement. “Going forward, I am confident that our military will act on lessons learned from this operation to strengthen our fight against our terrorist enemies.”

The White House has been feuding with critics of the Jan. 28 Yemen operation targeting a powerful branch of al-Qaeda. The Pentagon said U.S. Navy SEAL William “Ryan” Owens was killed in the raid along with 14 members of al-Qaeda in the Arabian Peninsula.

Medics at the scene said 30 people were killed, including 10 women and three children, according to Reuters. The eight-year-old daughter of Anwar al-Awlaki, a U.S.-born al-Qaeda leader killed under former president Barack Obama, was also killed according to reports.

READ MORE: Al Qaeda leader in Yemen labels Donald Trump a ‘fool’, says US raids failed

Trump has been criticized for authorizing the mission over dinner, according to anonymous U.S. military sources, who also accused Trump of approving the mission without sufficient support in place.

White House press secretary Sean Spicer said Wednesday that any criticism of the operation does a disservice to the life of Owens.

“The action that was taken in Yemen was a huge success,” Spicer told reporters. “American lives will be saved because of it. Future attacks will be prevented. The life of Chief Ryan Owens was done in service to this country and we owe him and his family a great debt for the information that we received during that raid. I think any suggestion otherwise is a disservice to his courageous life and the actions that he just took. Full stop.”

Story continues below advertisement

WATCH: President Trump pays respects to 1st US soldier killed during his administration

0:38 President Trump pays respects to 1st US soldier killed during his administration President Trump pays respects to 1st US soldier killed during his administration

McCain shot back at Spicer in an interview with NBC and he recounted an episode from his time as a POW during the Vietnam War when American soldiers tried to rescue him and others from a prison.

“Unfortunately, the prison had been evacuated. But the brave men who risked their lives in an effort to rescue us prisoners of war were genuine American heroes,” he said. “Because the mission failed did not in any way diminish their courage and willingness to help their fellow Americans who were held captive.

“Mr. Spicer should know that story.”

How the fallout from the operation will affect relations between the U.S. and Yemen is unclear.

Story continues below advertisement

The New York Times reported Tuesday that Yemen had withdrawn permission for the U.S. to run special counter-terrorism operations. On Wednesday, Yemen’s government denied reports that it had ceased allowing U.S. access to its territory.