White House national security adviser John Bolton on Sunday outlined conditions for a U.S. troop departure from Syria that appeared to contradict President Trump’s insistence less than a month ago that the withdrawal would be immediate and without conditions.

Speaking during a visit to Israel, Bolton said that certain “objectives” must be achieved before a pullout could take place. “The timetable flows from the policy decisions that we need to implement.”

Bolton acknowledged that pockets of the Islamic State remain undefeated and that a quick U.S. pullout could endanger U.S. partners and allies in the region, as well as U.S. forces themselves.

Trump, who has declared the battle won against the militants, and just two weeks ago said he refused military entreaties for more time, said Sunday that he remained committed to the withdrawal but told reporters: “I never said we’re doing it that quickly.”

Among the policy decisions still to be made is what to do about the tens of thousands of Syrian Kurdish fighters that U.S. forces have trained, armed and advised to carry out the ground war against the Islamic State.

In this Dec. 13, 2018 file photo, national security adviser John Bolton unveils the Trump Administration's Africa Strategy at the Heritage Foundation in Washington. The White House has sent Bolton on a mission to allay Israel's concerns about President Donald Trump's decision to withdraw U.S. troops from Syria. The pullout announced before Christmas was initially expected to be completed within weeks, but the timetable has slowed as the president acceded to requests from aides, allies and members of Congress for a more orderly drawdown. (Cliff Owen/AP)

Turkey, a NATO ally, considers them terrorists and has vowed to drive them out of the northeastern Syrian territory seized from the militants as soon as the Americans leave.

“It’s also very important that as we discuss with members of the coalition, [and] other countries that have an interest, like Israel and Turkey, that we expect that those who have fought with us in Syria . . . particularly the Kurds,” not be put in “jeopardy” by the withdrawal, said Bolton, who plans to travel Tuesday to Ankara.

While Trump has expressed confidence that Turkey, which controls its own Syrian force opposed to both the Kurds and to President Bashar al-Assad, is capable of picking up the remaining fight against the Islamic State, Pentagon and State Department officials question Turkish priorities and capabilities.

Turkish officials have also said they want the United States to provide air and logistical support for their operations in Syria.

Bolton and Secretary of State Mike Pompeo have stated repeatedly in recent months that driving Iran from Syria was also an objective for both the United States and Israel.

But Trump appeared to indicate Sunday that both Iran and Russia, whose forces in Syria back Assad, were potential U.S. allies against the Islamic State.

“Iran hates ISIS more than we do if that’s possible,” he said, using an acronym for the militants. “Russia hates ISIS more than we do. Turkey hates ISIS, maybe not as much as we do, but these are countries that hate ISIS, and they can do a little bit of the fighting in their neighborhood also because we’re fighting them in their neighborhood.”

“With that being said, we’re pulling out of Syria but we’re doing it, and we won’t be finally pulled out until ISIS is gone,” Trump said.

Trump touched off global confusion and panic when he announced via Twitter on Dec. 19 that he would order the withdrawal of the 2,000 troops stationed in Syria. “Our boys, our young women, our men, they’re all coming back and they’re coming back now. We won,” Trump said. White House spokeswoman Sarah Sanders added that “we have started returning United States troops home.”

On Dec. 23 — after Defense Secretary Jim Mattis resigned in protest of Trump’s withdrawal decision — Trump tweeted that he had discussed what he called a “slow and coordinated [U.S.] pullout” from Syria with Turkish President Recep Tayyip Erdogan.

During a Christmas visit to troops in Iraq, Trump said that he would deny any request from the military to extend the mission in Syria. “They said again, recently, ‘Can we have more time?’ ” Trump said of U.S. generals. “I said: ‘Nope. You can’t have any more time. You’ve had enough time.’ We’ve knocked them out,” he said of the Islamic State. “We’ve knocked them silly.”

Pompeo is also headed to the region this week to reassure Arab allies that the United States will not abandon them to either the Islamic State or to Iran. Reports that the Americans were leaving, said a senior administration official who briefed reporters Friday on Pompeo’s trip, were “false news” and there was no Syria departure timeline.

Plans and assurances offered by Bolton in Israel were additional confirmation that withdrawal plans are on hold until conditions on the ground match the president’s stated assessment of the situation in Syria.

In a news conference with Israeli Prime Minister Benjamin Netanyahu, Bolton said that “the defense of Israel and other friends in the region is absolutely assured,” that the Kurds and others would be protected, and that the administration would “make sure ISIS is defeated and is not able to revive itself and become a threat again.”

While Bolton’s reassurances may have come as a relief to some, a top House Democrat stressed that the priorities the national security adviser outlined were “obvious” — and simply highlighted how dangerous Trump’s initial withdrawal announcement was.

“We don’t want ISIS to rise again and be a transnational terrorist threat, and we don’t want our allies the Kurds to be slaughtered by Erdogan in Turkey. That was obvious,” House Armed Services Committee Chairman Adam Smith (D-Wash.) said Sunday on ABC News’s “This Week.”

“I’m pleased that John Bolton has recognized the national security interest, and that’s what we want to have,” Smith said, “ . . . not a tweet going ‘Eh, let’s get out of Syria.’”

Smith said he hoped to have Mattis testify before his panel, calling the former defense secretary’s views “invaluable.”

In his resignation letter, Mattis noted disagreements he’d had with Trump over the president’s approach to U.S. allies and adversaries and stated that Trump deserved a defense secretary whose views would be more aligned with his. Smith was more succinct in his assessment of Trump’s approach to global relations, saying Sunday that “our allies matter enormously and the president treats them like dirt.”

Republicans, too, have worried about whether the president is listening to his advisers, warning him that the administration’s actions in Syria will affect the United States’ reputation globally. At the time of Trump’s announcement, some wondered openly whether he was unduly influenced by foreign leaders such as Erdogan, whose agenda in the region is somewhat different from that of the United States.

Asked Sunday on CBS’s “Face the Nation” whether Bolton’s comments were an admission that Trump had “made a mistake,” Sen. Lindsey O. Graham (R-S.C.) said, “I think this is the reality setting in that you got to plan this out . . . He has a goal of reducing our presence. I share that goal. Let’s just do it smartly.”

“There are three things we want to accomplish as part of a withdrawal,” Graham said. “We want to make sure that, when we leave, the Kurds do not get slaughtered . . . We need to make sure ISIS doesn’t come back once they’re defeated, and Iran is not the biggest winner.”

Trump, he said, “is slowing down and he’s reevaluating his policies in light of those three objectives.”

Similar questions arose last week, after Trump offered a perplexing take on world history, incorrectly claiming that the Soviet Union’s 1979 invasion of Afghanistan was to combat terrorists infiltrating into Soviet territory, and that the invasion — and the 10-year war that followed — were the cause of the Soviet Union’s 1991 collapse.

White House Chief of Staff Mick Mulvaney distanced himself from those comments Sunday, defending the advice that he and others give Trump.

“The fact that he makes a decision that might be different than his advisers doesn’t mean that he’s getting bad information,” Mulvaney told CNN. “It means he’s relying on information other than what his advisers are giving him.”