The Senate approved a short-term spending bill Thursday afternoon with less than 12 hours to spare before a government shutdown deadline, aligning their proposal with a House bill and sending it to President Trump's desk.

The measure was passed on a 74-20 vote.

The U.S. government is funded through 11:59:59 p.m. ET Thursday night. Lawmakers in the Democrat-controlled House and the GOP-controlled Senate have struggled to reconcile their differences on spending, particularly on Trump's continued demand for border wall funding. That was also the cause of the government shutdown last winter after Trump decided last-minute he would not sign a bill that didn't include funding for a border wall. Trump has indicated he would sign the bill the Senate just passed, but if he does not it would be the third government shutdown under his administration.

Rep. Nita Lowey, D-N.Y., said last week that the measure "is necessary to keep government open as we work towards completing the appropriations process."

Senate Majority Leader Mitch McConnell, R-Ky., walks to the chamber on the morning after House and Senate negotiators worked out a border security compromise hoping to avoid another government shutdown, at the Capitol in in Washington, Tuesday, Feb. 12, 2019. (AP Photo/J. Scott Applewhite)

WHITE HOUSE TO SET UP CAMERAS TO LIVESTREAM BORDER WALL CONSTRUCTION: REPORT

The bill would fund the government through Dec. 20, setting up yet another late-year showdown over government spending for which border wall funding will likely be center stage. At that point, it's likely impeachment will still be at the forefront of Congress' agenda, whether it is still in the House or is shifted to the Senate for a trial by then.

The measure passed Thursday contains an assortment of technical provisions to ensure spending on the decennial U.S. Census can ramp up despite delays in the agency’s full-year funding bill. It also reverses a planned cut in highway spending next year and offers greater assurances about funding a 3.1 percent pay raise for the military that takes effect Jan. 1.

It also extends surveillance-related provisions of the Foreign Intelligence Surveillance Act that expire Dec. 15 for another three months, including a provision allowing the government to gain access to business records and conduct roving wiretaps of people trying to duck surveillance.

CLICK HERE TO GET THE FOX NEWS APP

The provision has drawn criticism from some members of Congress, including Rep. Justin Amash, I-Mich., who have opposed the warrantless surveillance the act allows as unconstitutional.

"The House’s short-term spending bill (continuing resolution/CR) extends expiring, unconstitutional provisions of the Patriot Act until March 15, 2020," he tweeted earlier this week. "The Patriot Act shouldn’t be extended even for one more day. Every representative in Congress should oppose this legislation."

Fox News Chad Pergram and Andrew O'Reilly and The Associated Press contributed to this report.