President Trump kept his promise and began the process to extricate the U.S. from the inherently flawed nuclear agreement with Iran known as the JCPOA. Before doing so, his administration embarked on a months-long process led by the National Security Council to arrive at an understanding with Europe that would at least plug the substantial holes in the accord.

Unfortunately, the three countries crucial to that effort, known as the E3 (the United Kingdom, France, and Germany), did not adequately engage or produce the kind of fixes on inspections, verifications, ballistic missiles, and sunset clauses necessary to justify keeping the accord in place. In essence, President Trump decided that rather than continuing to bail water aboard Team Obama’s sinking ship, he will build a new and sturdier vessel.

Leaving the nuclear deal allows the U.S. to reimpose painful economic sanctions on Iran and it re-establishes American leverage to work toward a better deal. That means the U.S. target is actually the E3. Before even working on Iran, the U.S. and the E3 need to reach an agreement on what constitutes a good deal. That will require that the E3 understand that a new nuclear deal will have to be about preventing Iran from ever getting nuclear weapons—not about improving their ability to conduct business with the rulers in Tehran.

Iran will likely remain in the agreement and seek to drive a wedge between the U.S. and the E3. Why not? The deal is that good from their perspective. JCPOA proponents repeatedly said, “Iran isn’t cheating.” But it doesn’t have to. After all, by sticking to the deal they will still be able to continue making advances in their ballistic missiles program, improve their nuclear technology, upgrade their centrifuges, and continue to work on computer modeling, miniaturization, and detonators at sites beyond the IAEA’s reach. That is how bad the JCPOA was; it’s an affront to anyone who understands the nature of the Iranian regime.

The talking heads, the deal’s defenders, and members of Obama’s echo chamber will continue using the same tired arguments and straw men they used in 2015 when they sold it to the American people. But the fact remains: There is no rational explanation for why the U.S. not only caved on every critical area in the agreement but also gave up all the financial goodies to Iran upfront, regardless of its compliance. Team Obama’s legacy is one of the worst agreements the U.S. has ever been a party to and by taking this step today and maximizing American leverage, President Trump can begin building a new nuclear accord that will actually keep Iran from developing nuclear weapons. That’s a legacy worth having.

Matthew RJ Brodsky is a senior fellow at the Security Studies Group in Washington, D.C.