Congress passed a measure Thursday to keep the government running for two more weeks, sending it to President Donald Trump for his signature.

The legislation, passed by voice vote in both chambers, would fund parts of the government at current levels through Dec. 21 and avert Friday's shutdown deadline. It would give lawmakers more time to hash out an agreement on spending and Trump's demand for $5 billion to fund his proposed border wall.

Congress has approved spending bills for five government agencies, such as the Departments of Defense and Health and Human Services. It has to fund seven more, including the Department of Homeland Security, which has emerged as the biggest sticking point as Congress tries to avoid letting funding for those agencies lapse.

Both House Minority Leader Nancy Pelosi, D-Calif., and Senate Minority Leader Chuck Schumer, D-N.Y., will huddle with Trump on Tuesday to discuss spending, a person familiar with the meeting said. Both Democratic leaders have resisted Trump's calls for money for a border barrier.

Senate Democrats have said they would approve $1.6 billion for border security, to fund fencing but not a physical wall. House Democrats, who will have control of the chamber in January, are more skeptical.

On Thursday, Pelosi told reporters that she would not exchange border wall funding for legal protections for young immigrants brought to the U.S. illegally as children — a legislative priority for House Democrats. She called them "two different subjects." Pelosi wants to fund DHS for a year rather than pass a short-term measure that would only delay the wall fight temporarily.

Before the 2018 election, in which the Democrats won the House, the party's leaders appeared more open to that compromise.