Yesterday it was NBC that bore the brunt of President Trump’s most recent harangue about fake news. And this time, he didn’t just attack NBC’s reporting, he also threatened to revoke the network’s broadcast license, hinting at a more aggressive political maneuver to come if needed to silence the opposition.

Despite Trump’s recent proclamation that he invented the moniker fake news, efforts to delegitimize opponents in the press have actually been deeply ingrained in American politics since the nation’s founding, and politically dangerous. While the First Amendment protects freedom of the press, in 1798, the specter of “fake news” fueled passage of the Sedition Act, which limited the scope of legal criticisms of the government. Like John Adams before him, Trump’s attacks threaten to stifle and undermine the press, but if he acts on them, they also might just blow up in his face.

In the 18th century, fake news was out of control. The earliest U.S. newspapers shared news with little regard for accuracy. In 1731, Benjamin Franklin, who was then the editor of the Pennsylvania Gazette, expressed a widely-held sentiment when he suggested that printers should simply print whatever came in over the transom in hopes that “when Truth and Error have fair Play, the former is always an overmatch for the latter.”

By the era of the American Revolution, many printers took advantage of this precedent to build powerful political platforms. They frequently printed rumors and outright fabrications that confirmed their previously-held beliefs while insisting that it was not their job to verify news before printing it. In short, these outlets functioned much more like modern social media feeds than today’s newspapers or broadcast news programs.

As Federalists and Republicans grew increasingly distrustful of one another in the heated partisan cauldron of the 1790s, concern about fake news exploded. Commentators frequently complained that Americans were being “seduced” and “misled” by “delusions and misrepresentations.” Some Americans feared that these falsehoods were subverting the democratic process — and rumors ran rampant that printers, pamphleteers and provocateurs were colluding with agents from Britain or France.

In June, 1798, as the United States was slipping into the “Quasi-War” with France, arch-Republican printer Benjamin Franklin Bache published a letter from the French Foreign Minister Charles-Maurice de Talleyrand that tried to smooth over some of the diplomatic challenges facing the two nations. In response, Federalist commentators pounced on Bache for printing, as they saw it, lies from a foreign adversary. On the floor of the House of Representatives, Federalist George Thatcher denounced Bache as a foreign agent acting under the “order of the [French] Executive Directory.”

Federalists, led by President John Adams, dominated government and had grown tired of news accounts that they believed were intended to delegitimize their leadership. They used Talleyrand’s missive to push the so-called Alien and Sedition Acts, which limited the freedom of the press and the movement of foreign nationals.

They based the sedition law on the premise that the First Amendment never intended to protect false news. After its passage, Virginia lawyer Charles Lee defended the law by claiming that the Sedition Act did not restrain “truth, but endeavours to suppress wicked falsehoods.”

Congressional opponents of the Sedition Act argued that published falsehoods were a necessary byproduct of a free press. The Geneva-born Pennsylvania Congressman Albert Gallatin — who was precisely the kind of foreign rabble-rouser that Federalists distrusted — warned that if the proposal became law, it would allow the Federalists to intimidate and clamp down on purveyors of real news, leaving Americans with only their side of the story.

Gallatin’s accusation proved to be correct. After Adams signed the Sedition Act into law, his government quickly prosecuted printers and others for critical statements and reprinting news with which they disagreed.

Meanwhile, Federalists spread their own fake news with impunity. Henry Van Schaack, a New York Federalist, for example, asked a friendly newspaper editor to print some news that would serve “those federalists who have not information enough to invent any thing themselves from which they can make beneficial Deductions.” If he had “no news from abroad,” Van Schaack suggested, “why don’t you fabricate some?”

Ultimately, the Federalists’ gambit backfired. The electorate revolted against their attempts to limit press freedom. Anger over the Sedition Act contributed to Adams’ failed reelection bid and the national decline of the Federalist party. Moreover, in response to the Sedition Act, Americans articulated the robust vision of press freedom that we often take for granted today. In a final, ironic twist, Federalist writers and printers quickly found themselves victims of their own legislation after Thomas Jefferson won the presidency and began prosecuting his adversaries at an even higher rate than the Adams administration had done.

The Federalists were drawing on English common law precedents, which provided for the prosecution of speech that could destabilize the government. But in doing so, they failed to distinguish between their party and the government it controlled. They justified their restriction on free speech by reframing challenges to their leadership as unpatriotic attacks on American order and unity. This was their fatal mistake.

Today, President Trump is making a similar mistake. In response to an adversarial press and its investigative reporting, he has branded the mainstream media as not only his enemy but also the “enemy of the American people.” These attacks on the media might be dismissed as inappropriate, but harmless, bluster, if not for his musings about “opening up” libel laws so that he can sue media outlets for inaccurate reports or his new threat to challenge NBC’s broadcasting license.

Even more alarmingly, since the election, Trump has appropriated the term “fake news,” as a weapon to be deployed against his enemies. The phrase was originally intended to describe the manipulative and demonstrably false news stories (such as the infamous “Pizzagate” or the false claim that Pope Francis endorsed then-candidate Trump) that spread rapidly through social media and arguably contributed to Trump’s surprising victory.

But, like John Adams and the Federalists, Trump’s use of “fake news” serves political purposes. Instead of targeting conspiracy theories and hoaxes, Trump has unleashed the phrase against mainstream media coverage with which he disagrees in an attempt to blur the boundaries between respectable media outlets and purveyors of deception and to delegitimize portions of the American media that dare to criticize him in any way. Baldly attempting to advance this goal, Trump’s press secretary Sarah Huckabee Sanders recently insisted that there was “no difference” between the fake news created by Russian propagandists and American reporting that Trump’s team has deemed inaccurate.

Federalists pursued this same strategy in 1798. They took advantage of public anxiety concerning fake news to reimagine dissent as disorder and clamp down on their adversaries’ press freedoms.

Yet President John Adams and his allies misread the moment, resulting in dire electoral consequences. It is unclear if President Trump and the Republican Party will follow the Federalists down this path. Yet if the response to the 1798 Sedition Act is any guide, not only would they threaten a freedom essential to our democracy, but their political opponents just might get the last laugh.