Trump made the incendiary comment during a press conference with Pakistani Prime Minister Imran Khan, as the pair discussed America’s longest-running conflict.

“I could win that war in a week. I just don’t want to kill 10 million people,” Trump told reporters at the White House meeting. “If I wanted to win that war, Afghanistan would be wiped off the face of the Earth. It would be gone. It would be over, literally, in 10 days… I don’t want to go that route.”

The comment prompted confusion and anger in Kabul, where the office of President Ashraf Ghani issued a statement requesting clarification on Trump’s remarks, the Associated Press reported. The statement vowed that the country would never “allow any foreign power to determine its fate.” The president’s office also stressed that its continued partnership with the U.S. rests on common interests and mutual respect.

Trump’s outburst even drew criticism from America’s long-time enemy in Afghanistan—the Taliban. The militant organization issued its own statement following the president’s meeting with Khan. The Taliban said Trump’s threat was “irresponsible and we condemn it in the strongest terms.”

The extremist organization also warned that the goal of military victory in Afghanistan was “taken to the grave” by multiple historical empires, including the Mongols, the British and the Soviet Union.

“On the contrary, their Empires were wiped off the face of this earth but the Afghan nation proudly endured and will continue to endure, live and remain proud, Allah willing,” said the statement posted on the group’s Vice of Jihad website, according to the BBC.

The president campaigned on a promise to end American “forever wars,” and has been consistently critical of U.S. involvement in Iraq and Afghanistan. But for all his bluster, Trump has been unable to end the war in Afghanistan, in which more than 2,000 American troops have been killed since 2001.

Trump has long been keen to bring U.S. troops home, but has reportedly been constrained by senior aides and military officials. Last year, the president announced that half of the 14,000 American troops left in the country would be withdrawn.

Peace talks with the Taliban are ongoing, but in the meantime the Afghan government is struggling to hold its ground. Taliban fighters have grown increasingly well-equipped and confident in recent years. The group has been able to inflict ruinous casualties on government forces while launching repeated major attacks on significant targets, including provincial capitals and Kabul.