President Trump pressed Republican senators Monday to add more border money to a homeland security spending bill, threatening to shut down the government if he doesn’t get what he wants — even as the lawmakers urged him not to.

“We did talk about a shutdown, that a shutdown’s in no one’s interest,” said Sen. Richard C. Shelby (R-Ala.), chairman of the Senate Appropriations Committee. Shelby wouldn’t say whether Trump agreed, and later two administration officials said the president had repeated a threat to shut down the government this fall over funding for the border wall.

That’s an outcome congressional Republicans are desperate to avoid when the current budget year ends Sept. 30, just ahead of the November midterm elections that will decide control of Congress. But Trump has at times spoken of a “good shutdown,” making it uncertain what he will do if government funding runs out and he’s confronted with a situation where, in all likelihood, he doesn’t get the $25 billion he has demanded for the wall.

Shelby met with Trump along with Sen. Shelley Moore Capito (R-W.Va.), who chairs the Appropriations subcommittee on homeland security. Shelby said they tried to impress upon Trump that because the homeland security spending bill had to be bipartisan, they could get only so much.

“The president is focused on border security, and he’d like more money. We talked to him that we thought this was a good down payment,” said Shelby, who indicated no plans to change his spending bill despite the president’s threat.

“I told him we were trying to work to achieve border security, too,” the senator added. “But we want to keep the appropriations process going, and this is a way to keep it going.”

Trump has repeatedly promised to build a wall along the U.S.-Mexico border, a proposal Democrats have rejected and fought against paying for. During his presidential campaign, Trump repeatedly promised that Mexico would pay for the wall.

Shelby declined to say how much money the bill would commit to the border for the 2019 budget year. The White House initially requested $1.6 billion for border-security elements — the same amount Congress committed in the 2018 budget year. But White House officials later indicated they wanted more, about $2.2 billion.

Shelby said the administration would be getting more than it did last year. But a Senate Democratic aide said later that the funding level of $1.6 billion for border barriers remained about the same. The aide spoke on the condition of anonymity to speak freely, as did the administration officials who described Trump’s demand.

The meeting about border funding occurred against the backdrop of a roiling debate over the administration’s decision to begin separating immigrant children from their families arriving at the border. White House officials insist it is Congress’s job to fix the issue through legislation, and the House will be voting on immigration bills this week, although they appear unlikely to pass.

But that issue did not arise as Shelby and Capito met with Trump, both senators said. Instead they were focused on funding levels in the annual spending bill for homeland security operations, which Capito’s subcommittee is scheduled to vote on Tuesday.

Senators and House members have been trying to get their annual funding process back on track after dysfunction in recent years. They want to avoid presenting Trump with a mammoth spending bill at the end of the fiscal year, which could further incite his shutdown threats. Trump vowed in March, after suffering conservative blowback for signing an enormous $1.3 trillion spending bill that broke spending caps, that he would never sign another such bill.

Josh Dawsey contributed to this report.