The Senate passed a $741 billion defense authorization bill Friday with a veto-proof majority, defying President Trump’s repeated threats to scuttle legislation that covers funding for most aspects of the military, from overseas operations to pay raises for troops.

The 84-to-13 vote, and a similarly lopsided result in the House earlier this week, leaves the president with a pivotal dilemma in the final weeks of his administration: accept defeat now and sign, or go down fighting in a veto battle with Congress that he is certain to lose.

Trump will be contemplating his decision as he and his most loyal supporters enter the final stage of their effort to reverse the outcome of the presidential election, which electors are expected to certify Monday and Congress must formalize early next month. How the president handles the defense bill may influence how Republicans respond to his continued railing against the election results.

Trump has been offering shifting veto threats against the defense bill for months, first promising to reject it over a dispute about renaming military bases that commemorate Confederate leaders, and later over unrelated liability protections for technology companies.

Republican lawmakers and lobbyists have been working for months to get Trump to back down from his pledges to block the legislation’s progress, arguing that the military operations and other programs the bill authorizes are too important to jeopardize.

Only 47 Republicans heeded Trump’s calls to vote down the defense bill this week: seven senators and 40 members of the House, which passed the bill Tuesday by a vote of 335 to 78. The president has not publicly repeated his promise since lawmakers approved the legislation.

But he also has not rescinded his numerous veto threats, leaving Congress in a holding pattern as lawmakers wait to see what the tempestuous president will do.

Once Congress formally delivers the bill to the White House, Trump has 10 days — excluding Sundays — to decide whether he will sign or veto the legislation. If he does neither, and Congress is still in session, the bill automatically becomes law.

If the president runs out the clock, the final decision could come on or around Christmas, making the defense bill the latest reason lawmakers may have to work through the holidays. Congressional leaders have already been considering keeping the legislature in session to force a resolution to the months-long negotiations over another coronavirus relief package as the country heads into the worst throes of the pandemic.

The president’s veto threats have been hanging over the bipartisan defense bill since the summer, when each chamber voted on separate versions of the legislation that were later reconciled through negotiations.

At first, Trump focused his ire on provisions requiring the Pentagon to change the names of installations commemorating Confederate leaders within a limited time frame, insisting they be stripped out even as his allies pleaded with him not to hold up the defense bill for a matter that, they argued to him, would put him on the wrong side of history.

In recent weeks, Trump shifted his attention, demanding that the bill include a repeal of Section 230 of the Communications Decency Act, an unrelated law that shields technology companies from legal liability for content posted by third-party users on their websites.

The president’s fixation on Section 230 reflects the White House’s war with Facebook, Google and Twitter over allegations that they are biased against conservatives — claims that the three tech giants deny.

Lawmakers ignored both of Trump’s demands in the final bill, which contains many other rebukes of his tenure as commander in chief.

The defense bill would restrict the president’s emergency authority to redirect military construction funds, setting a limit of $100 million per year for domestic projects — a retort to Trump’s moves to repurpose billions in such funds for his border wall project.

The bill would also curb the administration’s ability to reduce troop levels in Germany, South Korea and Afghanistan without making significant justifications to Congress. While the provisions will pose a longer-term constraint on President-elect Joe Biden, they are a direct answer to Trump’s past efforts to withdraw U.S. forces from various theaters, over the objections of leaders in his own party.

But those provisions upset Sen. Rand Paul (R-Ky.), who staged a procedural protest of the Senate bill this week to make the point that the president ought to have the right “to end a war, not just to start wars.”

Paul’s protest initially stirred alarm, as senators worried that the delay on the defense bill would have a domino effect and waylay a necessary vote on a one-week deal to temporarily replenish the federal budget, which was otherwise set to expire Friday at midnight. But Paul relented late Friday morning, saying he had no intention of causing a government shutdown. Congress passed the budget bill, and Trump signed it late Friday.

Trump and his advisers have also objected to the limitations on troop reductions, listing those earlier this week as one of several reasons the president would reject the bill. It is not clear if their silence since the bill passed is an indication that the president will abandon his protest and sign the measure.

The defense bill has been ultimately signed into law for each of the past 59 years, a streak that no longer appears to be in jeopardy after this week’s votes. But if the president vetoes the legislation, it is likely to still make history as the first time in those years that the defense bill became law via a veto override.