On Thursday night, Donald Trump made a major economic announcement in the forum where all U.S. policy now occurs, Twitter. Fuming about the proliferation of undocumented immigrants coming into the country, President Trade Wars Are Good And Easy To Win said that starting June 10, he will impose a 5 percent tariff on all Mexican imports, a tax that will “gradually increase” to 25 percent and remain there until Mexico cracks down on people crossing the border into the U.S. The reaction to the move was, in a word, bad. In three words, really freaking bad. Terms like “disastrous,” “baffling,” and “colossal blunder” were thrown around, and with good reason: blanket tariffs on Mexican goods will have a serious impact on American consumers and companies—the ones already paying for Trump‘s ongoing trade war with China—and not in a good way. Glen Hamer, chief executive of the Arizona Chamber of Commerce, told the Washington Post the levies “will be terribly damaging.” Also, not very smart if the goal is to stop people from coming into the U.S., given that, should the tariffs damage the Mexican economy—which of course they are designed to do—more of its citizens might want to cross the border to find jobs. The Dow Jones Industrial Average, unsurprisingly, dropped 350 points, since investors were hoping Trump was about to end his self-defeating feud with Beijing, not start a new one with our biggest trading partner. So how did the incredibly dumb move—even by the standards of this collection of people—come to pass? Apparently the answer is Stephen Miller.

CNBC reports that while all of Trump’s actual economic advisors were opposed to the tariffs—which are typically used to counter trade violations, not as a border enforcement mechanism—they were pushed hard by Miller, who has spent his entire time in the White House using whatever means necessary to keep (non-white) people out of the country. (Most recently, he proposed busing detained immigrants to sanctuary cities in blue states as retribution for opposing his agenda.) Knowing that Treasury Secretary Steven Mnuchin, U.S. Trade Representative Robert Lighthizer, and National Economic Council director Larry Kudlow were staunchly opposed to what is, effectively, a tax on U.S. corporations and consumers, Miller seemingly struck at just the right moment. According to reporters Kayla Tausche and Tucker Higgins, Kudlow—who admitted the truth about who pays for these trade wars last month—is currently out of the West Wing for surgery on his hip. Per the Wall Street Journal, Lighthizer “tried to talk the president out of the move.”

Miller, whose role in making the Mexico tariffs happen was confirmed to CNBC by two sources, has made no secret of his disdain for immigration of any kind. Last month, he reportedly “demanded” to know why administration officials were taking so long to implement a regulation to deny welfare to legal immigrants that the angry 33 year-old predicted would be “transformative.” He was also unhappy about a lack of progress in overturning court-ordered protections for migrant kids, enraged that his fellow staffers weren’t eating undocumented children for breakfast. “You ought to be working on this regulation all day every day,” he reportedly shouted. “It should be the first thought you have when you wake up. And it should be the last thought you have before you go to bed. And sometimes you shouldn’t go to bed.” By numerous accounts, Miller was behind Trump’s purge of the Department of Homeland Security, which he believed was necessary because officials weren’t working fast enough on policies that “were legally questionable, impractical, unethical or unreasonable.”

Of course, it’s not entirely surprising that an lifelong xenophobe would be willing to put his white rage ahead of economic principles but it’s more than a bit concerning that he was actually successful at it.