In the days and months before President Donald Trump announced he would withdraw the United States from the Paris accord, climate-change deniers were preparing for the worst. Trump twice postponed meetings about whether to remain in the agreement, raising questions about whether Trump would cave to overwhelming pressure from some of his closest advisers (not to mention scientists, corporations, and the international community). “His views are evolving,” Gary Cohn, Trump’s chief economic adviser and a supporter of the agreement, claimed in late May.

This was supposed to be a straightforward decision. On the campaign trail, Trump promised to “cancel” the accord. After his election, he appointed libertarian think-tanker Myron Ebell—an ally of the fossil-fuel industry who has been labeled a “climate criminal” by green activists—to lead the Environmental Protection Agency (EPA) transition. After inauguration, Trump appointed then–Oklahoma Attorney General Scott Pruitt, another climate denier who’s cozy with industry, to lead the EPA, and signed executive orders directing the EPA to dismantle climate-change regulations.

But two months in, some prominent members of the denier community began to worry. “We have a problem,” Ebell said at a March conference for the Heartland Institute, an organization dedicated to discrediting climate science. “Swamp creatures are still [at the White House]. They are trying to infiltrate the administration. And some of them are succeeding.” Alarmed by Trump’s indecision on Paris, Ebell’s organization—the Competitive Enterprise Institute, which is partly funded by coal companies—began running television ads pressuring Trump to exit.

Paris wasn’t the only issue raising alarms, as several members of Ebell’s EPA transition team expressed concerns about Pruitt. They complained that he wasn’t speaking strongly enough against climate science; wasn’t acting quickly enough to repeal regulations; and had not acted to undo the EPA’s categorization of carbon dioxide as a pollutant. Breitbart’s James Delingpole—one of the most prolific anti-environmentalist trolls on the internet—tore into Pruitt and Trump for not being aggressive enough in rejecting climate science, and even suggested Pruitt consider resigning. “If the Trump administration is serious about dealing with the vast and out-of-control Climate Industrial Complex which has done so much harm to the U.S. and the world these past few decades, then it is going to need to seriously up its game,” Delingpole wrote.

Then Trump decided to withdraw from Paris after all—the debate was “mostly a charade,” Axios reported—and the president and Pruitt were denier-heroes once more. Ebell took to the cable news shows to praise the president. Breitbart celebrated, too. “I thought [Trump] was going to fudge it much more than he did; that he’d end up compromising to please Ivanka,” Delingpole wrote. “Just when even some of his fans were starting to doubt him, he has made his presidency great again.”