President Donald Trump signed a bill Monday night ending the government shutdown, capping off a nearly three-day deadlock and reinstating funds until February 8, a senior administration official said. The House and the Senate voted Monday to end the government shutdown, extending funding for three weeks, following a deal being reached between Senate Minority Leader Chuck Schumer and Senate Majority Leader Mitch McConnell regarding assurances related to immigration. The House passed the continuing resolution 266-159, with 36 more yes votes than the four-week resolution they passed last week. The movement comes thanks in part to commitments from McConnell and other Republicans in bipartisan meetings, according to four Democratic sources. The votes came several hours after the workday for hundreds of thousands of furloughed federal employees was supposed to have begun, and it comes three days after the government officially shut down Friday at midnight. The movement comes thanks in part to commitments from McConnell and other Republicans in bipartisan meetings, according to four Democratic sources. “We will vote today to reopen the government,” Schumer said earlier on the Senate floor, saying he and McConnell had reached an “arrangement.” McConnell reiterated the same on the Senate floor, adding the shutdown was distracting senators from focusing on passing legislation. “I respect the passion that many of my friends in this chamber, Democrat and Republican alike bring to the major issue before the Senate, all of these issues,” McConnell said. “But we should not let the political feuds or policy disagreements obscure the simple fact that every member of this body cares deeply about the challenges facing our country.” He continued: “It’s evident that this government shutdown is doing nothing, absolutely nothing to generate bipartisan progress on the issues the American public care about.” The Senate passed the measure earlier Monday 81-18. The Senate vote was moved from 1 a.m. ET Monday to noon after it became clear Democrats would block the spending bill over disagreements on a variety of issues, most notably what do about young people affected by the expiring Deferred Action for Childhood Arrivals program. Flake said Sunday night he was now a “yes” on the funding bill and it was his hope that six or seven more moderate Democrats would come on board to get the continuing resolution over the finish line – to 60 votes – to end the shutdown. He said the Democrats still want something tangible on DACA but said it was problematic because it could run into the February 8 funding deadline. He argued that they won a concession from McConnell that he isn’t requiring President Donald Trump to sign off before an immigration bill moves to the floor. “For the first time, we have the majority leader move off of we can only move something if the President agrees,” Flake told reporters. Earlier Sunday, Trump called for Senate Republicans to change the chamber’s rules to resolve the funding impasse as the government shutdown continued into its second day. He tweeted a call for McConnell to invoke the so-called “nuclear option” and thereby remove leverage for Senate Democrats. Senate rules impose a threshold of 60 votes to break a filibuster, and Senate Republicans currently hold a slim majority of 51 votes, meaning even if they can unite their members, they need nine more votes to end debate. The White House is calling for the Senate to change its rules and move the threshold to a simple majority of 51 votes. A spokesman for McConnell said in response to the tweet that the Senate Republican Conference does not support changing the 60-vote rule, a reiteration of Republican Senate leadership’s already-stated opposition to the move Trump has called for over the past year. This story has been updated and will continue to update with new developments Monday.