President Donald Trump issued a strange and threatening ultimatum to Kim Jong Un on Thursday.

It was in response to North Korean complaints about US demands for the country to rid itself of nuclear weapons.

Trump essentially compared North Korea to Libya, telling Kim, the North Korean leader, that he could either denuclearize his country or face war with the US.

North Korea recently flipped out on the US, bashing Trump's administration and its policies, and Trump has gone back to hawkish rhetoric just as fast.

The episode should remind us that, as long as North Korea has nuclear weapons, we are a hair's breadth from nuclear war.

President Donald Trump addressed a key North Korean complaint on Thursday, ahead of a planned historic summit between Trump and Kim Jong Un.

But in doing so he evoked the threats that brought the world to the brink of nuclear war in 2017.

Asked about comments by his national security adviser, John Bolton, that the White House was looking at a "Libya model" for ridding North Korea of nuclear weapons, something to which North Korea responded angrily, Trump essentially issued an ultimatum: Denuclearize or die.

The ultimatum was clear, but Trump's understanding of the history of disarmament in Libya was not.

"The model, if you look at that model with Gaddafi, that was a total decimation," Trump said. "We went in there to beat him."

The US and other nations agreed with Libya in 2003 to remove the Libyan ruler Muammar Gaddafi's nascent nuclear weapons program and his chemical weapons.

Gaddafi gained international acceptance as a result, and he ruled for eight more years until a popular uprising plunged his country into civil war.

The US, along with NATO allies, then backed the uprising against him, and attacked Gaddafi's forces, but did not kill Gaddafi.

Though the US strikes were effective, they were focused and did not "decimate" the country in the way that, say, US bombers pounded North Korea in the Korean War.

Gaddafi died within six months of the US intervention, but it was his own people who killed him after finding his hideout and dragging him through the streets.

Bolton's original comments about a Libya model appeared to address the disarmament in 2003, while Trump on Thursday appeared to address Gaddafi's death in 2011, something North Korea has picked up on and responded to.

A model involving national devastation for the country "would take place if we don't make a deal, most likely," Trump said. "But if we make a deal," he continued, "I think Kim Jong Un is going to be very, very happy."

Return to fire and fury

Donald Trump. Chip Somodevilla/Getty Images

On Monday, the US and North Korea were going into their fourth month of warming relations, preparing for a summit for Trump and Kim to discuss peace and possible denuclearization.

On Tuesday, North Korea threatened to back out of the talks, spewed vitriolic anti-US rhetoric, and reasserted itself as a nuclear power.

By Thursday, Trump was back to talking about decimation and framing North Korea's future as a choice between death or denuclearization.

Both Trump and Kim have incentives to keep the summit and peace push on track. But as Trump's comments on Thursday show, despite the hand-holding and peace talks, almost nothing has changed in North Korea, or with Trump.

Experts warn that a Trump-Kim summit carries huge risk. If the summit fails to achieve peace and agreement, the highest cards in both countries' diplomatic decks have been played, and all that remains is confrontation.

So far, 2018 has been almost clear of nuclear brinkmanship between Trump and Kim, but Thursday should remind us that as long as North Korea has nuclear weapons, the US stands a hair's breadth from war.