During the years drug firms poured millions of highly addictive pain pills into West Virginia amid a rise of overdose deaths, the U.S. Drug Enforcement Administration had a shortage of leadership in the state, according to a DEA official.

“We had no leadership in West Virginia. We had none,” said Karl Colder, special agent in charge of the Washington, D.C., field office, which covers Virginia, Maryland, the District of Columbia and West Virginia.

Between 2007 and 2012, drug wholesalers shipped 780 million hydrocodone and oxycodone pills to West Virginia, while 1,728 people fatally overdosed on those two powerful painkillers, the Gazette-Mail reported in December.

Before 2013, the highest-ranking DEA agent in West Virginia was a group supervisor, Colder said. Now, the DEA has a Charleston-based assistant special agent in charge who reports directly to Colder. The agency also has hired more agents and set up tactical diversion squads in Clarksburg and Charleston.

“In the past, they were just supervisors, and they had to run enforcement operations,” Colder said. “You had no leadership in West Virginia. This is the first time the community has seen the special agent in charge.”

Colder, who became special agent in charge in 2013, and four other DEA officials were in Charleston last week to announce the agency will spend $500,000 on a program that aims to reduce heroin and prescription drug abuse in Kanawha, Putnam and Cabell counties. West Virginia has the highest drug overdose death rate in the nation.

The night before their press conference in Charleston, the DEA agents talked about recent national reports that revealed agency lawyers had put the brakes on enforcement actions against drug distributors, starting in 2013.

Following the reports, the DEA announced drug giant McKesson agreed to pay $150 million to settle a case, and wholesaler Cardinal Health agreed to pay $44 million in fines.

“We also were targeting their DEA numbers, their registration numbers, but, unfortunately, if you read The Washington Post, you’ll know, unfortunately, there was some pressure,” said Ruth Carter, the DEA’s diversion program manager. “We were told you know.”

Five former DEA supervisors told The Post they were frustrated by the sharp drop in enforcement actions. The former head of the diversion office, Joseph T. Rannazzisi, said he was summoned to a meeting in 2012 during an investigation of Cardinal Health. Rannazzisi told the The Post he was chastised for “going after industry.”

Carter said a Department of Justice lawyer, whom she didn’t name, directed agents to halt an ongoing investigation against Cardinal Health, the nation’s second-largest drug wholesaler.

“One DOJ official told us we could not pursue Cardinal any further,” Carter said. “That’s the only thing I know that’s true. Yes, they did. But those people aren’t at DOJ anymore. Everyone at DEA, we want to do the right thing.”

Carter later clarified none of her superiors tried to kill the investigation outright.

“We were told not to go any further,” she said. “‘You’ve done enough investigating. Let’s just process the case.’”

Last month, Cardinal Health and wholesaler AmerisourceBergen abruptly agreed to settle a four-year legal battle with the state of West Virginia, which had accused the companies of fueling the state’s prescription drug problem. Cardinal Health and AmerisourceBergen paid a combined $36 million — the largest pharmaceutical settlement in state history. The money will go to drug treatment programs that help West Virginians addicted to opioids.