President Donald Trump thanked Senate Minority Leader Chuck Schumer, D-N.Y., for getting Democrats on board with the Republican spending package to keep the federal government open.

The Senate voted late Friday afternoon to advance the continuing resolution, a short-term spending bill. That cleared the way for a final vote to avert a government shutdown.

“I mean, I was told that that was what was going to happen,” Trump told The Daily Signal on the tarmac of Joint Base Andrews in the Maryland suburbs of Washington. “And I appreciate Sen. Schumer, and I think he did the right thing, really. I’m very impressed by that.”

The Daily Signal depends on the support of readers like you. Donate now

After initially staunchly opposing the bill, Schumer agreed to vote for the continuing resolution because “a shutdown would be a gift” for Trump and Republicans. All told, nine Democrat senators and one nominal independent who caucuses with them sided with all but one Republican to advance the CR on a vote of 62-38, two more than the minimum of 60 needed.

If Democrats had refused to advance the CR, they would have been seen as responsible for the shutdown, which would have likely caused grief for Democrat members of Congress in swing districts in the midterms.