The Choice, Frontline’s quadrennial documentary about the two final candidates who have become the major-party presidential nominees, made a remarkable argument this cycle around. Donald Trump’s candidacy, the documentary suggested, may have arisen as a result of some jokes made by President Obama. During the height of Trump’s birther phase in 2011, Obama gave a speech at the White House Correspondents’ Dinner, laying into Trump with joke after joke.

“It just kept going and going,” recalled Trump’s now-campaign staffer, Omarosa Manigault, “and he just kept hammering him. And I thought, ‘Oh, Barack Obama is starting something that I don’t know if he’ll be able to finish.’” Trump’s fellow adviser, Roger Stone, agreed: “I think that is the night that he resolves to run for president. I think that he is kind of motivated by it. ‘Maybe I’ll just run. Maybe I’ll show them all.’”

President Obama made what will likely be his final appearance, as president, on Jimmy Kimmel Live! on Monday evening, and in many ways the event was a fitting coda to the events of the Nerd Prom of 2011. It was inevitable that the comedian and the politician would discuss Trump, and Trump indeed was a spectral presence throughout the proceedings. But not just there: He was everywhere, and not just as a joke, but as a warning. Obama, with his uninvited guest, brought a note of the ominous to the otherwise cozy late-night couch, suggesting that the era of 2011—the time when Trump could exist simply as a punchline—is over.

Things started cheerily enough, with the president’s appearance on Kimmel’s semi-regular series, “Celebrities Read Mean Tweets.” It was Obama’s second time participating in that—dramatically reading the criticisms people had tweeted at his expense—and an extremely funny one. Some of the tweets the president read:

— Barack Obama is the Sharknado of presidents. Loud, stupid and over-hyped. #sharknado4

Obama couldn’t negotiate getting a whopper without pickles.

I just found out my daughter shares a birthday with Obama. PUKE!

My mom bought a new conditioner and it sucks. It isn’t even conditioning my hair. I blame Obama.

Obama concluded his reading, however, with a specially selected mean tweet: “President Obama will go down as perhaps the worst president in the history of the United States!”

Obama paused. The tweet was from @realdonaldtrump.

He paused again, getting the timing perfectly.

“Well, @realdonaldtrump, at least I will go down as a president,” Obama said. Then he dropped the mic smartphone.

During Kimmel’s interview segment, though, things stayed on the topic of Trump but took a much more serious turn. The two engaged in typical small talk—about the mozzarella sticks backstage that Obama snacked on, about the Cubs’ participation in the World Series, about Bill Murray’s recent meeting at the White House—but quickly moved on to politics. Obama and Kimmel discussed Hillary Clinton: In response to Kimmel’s question about why so many people seem to distrust her, the president explained that “a lot of this just has to do with the fact that she has been in the trenches, in the arena, for 30 years.” They talked about Obama’s post-presidency life, and the family’s plan to stay in Washington. “I’m like the old guy in the bar where you went to high school,” Obama joked—“just kind of hanging around.”

But then: Trump. Trumpety-Trump Trump. “When you watch Trump in the debate,” Kimmel asked, “do you ever laugh?”

“Most of the time,” Obama replied.

They talked about the Access Hollywood video. “I think that’s one of those things where, if your best friend who worked in the office somewhere had that video, it’d be a problem for him,” Obama said. “And he’s not running for president.”

Things built, then, to another Trump question. “Do you ever wish you were running against Donald Trump?” Kimmel asked. “Do you ever wish you were in there?”

“You know, I think Hillary’s doing just fine,” the president responded.  

After a moment, though, he added:

We joke about Donald Trump, but I do think that part of the reason you’ve seen Michelle so passionate in this election, part of the reason that we get involved as much as we have, is not just because we think Hillary is going to be a great president, but it’s also because there is something qualitatively different about the way Trump has operated in the political sphere.

And this is where the President Obama of 2016 had his moment of reckoning with the President Obama of 2011. The appropriate response to Trump, he suggested, is no longer to laugh him off. It’s no longer to do what a late-night show used to be all about: to mock the candidates in an equal-opportunity way. We are beyond that now. Late-night comedy is also, in some sense, beyond that. “Look, I ran against John McCain,” the president said. “I ran against Mitt Romney. Obviously, I thought that I could do a better job. But they’re both honorable men, and if they had won, then I wouldn’t worry about the general course of this country.”

The president paused, now timing his non-joke perfectly. He continued:

I think Republicans and Democrats have some fierce disagreements, and that’s how democracy works—we’re a big, diverse country, and sometimes it’s going to be contentious and noisy. But what we haven’t seen before is somebody questioning the integrity of elections and the will of the people. What we haven’t seen before is a politics based on putting down, in very explicit terms, Muslim Americans, who are patriots, or describing women not in terms of their intellect or character, but on a 1 to 10 score.

It was a speech, essentially, delivered from a plush, late-night couch. It was purposely un-funny. It was an iteration of his wife’s phrase, which has recently been adopted as a kind of rallying cry: “When they go low, we go high.”

Kimmel, the consummate late-night host, tried to lighten the mood, looking for some hi-larity in all the heights. As the president continued his speech—“regardless of what your policy preferences are,” Obama said, “there is a certain responsibility and expectation in terms of how you behave, how you present yourself—”

Kimmel interrupted him.

“I’ve heard this speech before, believe me,” Kimmel said.

“Yeah. It doesn’t mean that you’re perfect,” the president replied.

“No, I didn’t mean from you. I meant by guidance counsellors, to me.”

The president gave him a courtesy laugh. And then he continued with his speech.

“Yeah. Well, that’s the—the point is that I said when I was running in 2008, I’m not a perfect man, and I wouldn’t be a perfect president.” He added:

But I’d make the effort to, as best I could, be honest to the American people, to make sure that I was protective of the institutions, that there were certain norms and standards and values and customs that make it work. And if you are going to say anything and do anything, even when it undermines everything that’s been built by previous generations, that’s a problem. And that’s why I take this election very seriously.

“Seriously” is not a word that has traditionally fit in well with the antics of late-night comedy. And yet here we are. Trump has been anti-establishment not just when it comes to politics, but also when it comes to the broader sphere of entertainment: Comedians have been unsure, exactly, how to treat him. The president was in that sense making a political argument that was also about comedy: He was saying, essentially, that the time for simple jokes about Trump—the kind he made in 2011, the kind so many people have been making since Trump became a political candidate—has ended. This election hasn’t been about policy differences so much as it has been about divisions in basic decency; the comedy that helps people make sense of that election, for better or for worse, now needs to reflect that.