The U.S. House of Representatives passed a resolution to block President Donald Trump's attempt to build a wall along the U.S.-Mexico border using his emergency powers. 

The resolution passed by a vote of 245-182 with 13 Republicans joining the Democratic bloc and moving against the Republican president's decision. The next step for the resolution is in the Senate, where it must be taken up for a vote within the next 18 days. 

Interestingly, the vote total fell below the two-thirds of the House that would be necessary to override a presidential veto and Trump has said that he would veto attempts to subvert his national emergency declaration. 

Senate Majority Leader Mitch McConnell told reporters that he's unsure how the bill will fare in the Senate, a sign of the emergency declaration's unpopularity among representatives on both sides of the aisle. 

“I personally couldn’t handicap the outcome at this point," McConnell said, before noting that he's unsure whether Trump's declaration was even legal. “We’re in the process of weighing that.”

Trump's national emergency declaration came after a government shutdown gambit failed to produce a deal that would fund his pet project, a border wall. He's using the vague definition of what a president's powers are under a national emergency to work around the fact that the legislature flatly refused to fund the wall. Given that the ability to set the budget and pass laws is the main check that Congress has on any president, many representatives are questioning the legality of Trump's move. 

Speaker of the House Nancy Pelosi accused Republicans of forgoing their oath of office by refusing to check Trump over the power grab. 

“Is your oath of office to Donald Trump, or is your oath of office to the Constitution?” Pelosi asked ahead of the House vote.