Just two weeks ago, many Democrats were anticipating a harmonious end to their party’s unexpectedly prolonged presidential primary. They envisioned a scenario in which the forces of division within the party, which had recently intensified, might collapse under the weight of enormous historical forces.

Back then, though Hillary Clinton’s lead in California primary polls was an imposing 10 percent, her head-to-head lead in general election polls over Donald Trump had vanished. Trump had consolidated Republican support more rapidly than seemed possible after clinching his party’s nomination, and the notion that Democrats needed to put their primary behind them before Trump claimed the lead had taken on new urgency.

A resounding Clinton victory in the country’s most populous blue state, on the same night that she was projected to eclipse the number of delegates required to win the nomination, seemed like just the jolt the party would need to form a consensus behind her candidacy, against a surging Trump. With the nomination out of reach, Bernie Sanders might even concede defeat, while declaring a moral victory for a rising progressive wing of the Democratic Party.

It was never going to be quite so smooth. Around the same time, I argued that as a matter of political horse-trading, Democrats were going to have a harder time unifying their party after Clinton finally vanquished Sanders than they did in 2008, when Barack Obama defeated her. Unlike Clinton and Obama, Clinton and Sanders have substantial ideological differences, and substantially different theories of how the political system responds to public sentiment. When Obama beat Clinton, Democrats were desperate for a path out of the political wilderness; eight years after the George W. Bush presidency ended, it stands to reason that some of them have become frustrated by the Democratic establishment’s many inadequacies.

The events of the last two weeks have made unity more challenging still. The way the Clinton-Sanders race came to an end, amid signs that Trump’s general-election campaign will be a convulsive disaster, will only amplify the forces keeping the party divided. And the longer it remains divided between Clinton and Sanders supporters, the more marginalized and alienated Sanders’s supporters will grow, and the more attenuated Sanders’ influence—and the left’s—within Democratic politics will become.

It would thus behoove him, for the sake of his own movement’s viability, to suspend his campaign quickly, with a smile, and begin the work of drawing his supporters into the Democratic fold well before the party’s convention next month. Some progressives will grieve or protest, but ultimately their cause will be better served.

As if to foil the best laid-plans of both campaigns, the Associated Press declared Clinton’s victory on Monday night. AP had been tracking the private and public commitments of Democratic superdelegates for months, and those commitments were enough to put Clinton over the top after her overwhelming victory in Puerto Rico on Saturday. Other major media outlets quickly confirmed AP’s tally.

This electoral peculiarity, based on private testimonials rather than public statements or votes, robbed Tuesday night’s elections of suspense, and infuriated Sanders supporters, many of whom saw it as further evidence of a nominating system rigged in Clinton’s favor.

Most importantly, though, all of this transpired against the backdrop of a massive Republican civil war over Trump’s latest act of racist incitement against the federal judge overseeing fraud allegations against Trump University.

Normally, it’s great news for Democrats when Republicans are engulfed in chaos, and in important senses, it was: Clinton was able to eviscerate Trump in a speech about his erratic foreign policy pronouncements a week ago, contrasting her steady hand to his small-but-flailing one, and many Republicans seem ever more resigned to losing the presidential election in November.

But for the purposes of holding the Democratic Party together, Trump’s latest debacle was poorly timed. His lethal flaws—his racism, the division that his candidacy has sown in his own party, his inability to build a functional campaign—undermines the argument (made forcefully by Clinton supporters, if not Clinton herself) that Sanders would be unelectable. That the country would never elect a 74-year-old, self-identified socialist.

Amid this week’s Trumpenfreude, at this moment of much-anticipated closure, progressives are going to feel as if the Democratic Party rejected an opportunity to swing in a meaningfully more liberal direction in 2016, on the basis of an electability argument that at the moment seems clearly wrong. While the histrionic laments of Bernie-or-Bust Sanders supporters who say Sanders’s defeat is somehow “undemocratic” is false—she’s won a clear majority of Democratic votes, delegates, states, and super delegates—this remorse, which could easily turn to bitterness, is understandable. It is harder than ever, given the catastrophic start of Trump’s general-election campaign, to argue that Sanders wouldn’t win in November.

In truth, Clinton has been the Democratic Party favorite for years. Her political connections, fundraising prowess, and base of support pushed most potential competitors out of the race before they ever considered running. But the party was simultaneously relieved to have someone dependable on hand, prepared to take up Obama’s mantle, defend it against a reinvigorated Republican Party, and cement his accomplishments as the 45th president. These party actors and donors weren’t bullied into joining the Clinton juggernaut—they did it willingly. If Democrats coronated Clinton, they made that decision largely out of aversion to risk. Nobody knew Trump would run, or what his candidacy would really mean.

To Sanders’s supporters, this now reads like an error born of overcautiousness—or, more conspiratorially, like an intentional effort to freeze out the left before it ever had a chance to make a case for a more progressive candidate.

There are still many powerful forces pushing in the other direction, toward unity. Obama remains exceedingly popular among all Democrats, and his legacy will suffer if the country doesn’t elect a Democratic successor. Clinton’s candidacy is a matter of genuine historic import, and Trump is a walking obscenity.

Multiple reports have indicated that Obama is preparing to endorse Clinton—if not this week, then very soon. If Sanders remains serious about taking his campaign all the way to the convention—a pledge he again made in Los Angeles in his way-past-primetime speech last night—this means he will soon be running against the most popular Democrat in the country, and in the process, turning his supporters against Obama, deepening their animosity toward the Democratic Party, and sacrificing an immense amount of the goodwill he’s earned over the past year.

Bowing out gracefully, and soon, would solve both the Democrats’ problems and his own. The news flash late on Tuesday that Sanders will meet with the president on Thursday, reportedly at the senator’s request, could be a signal that he has begun to move in that direction. For the sake of the party, and for the good of the left wing he’s championed, he should move swiftly.