Amid the ongoing fallout from the protracted water crisis in Flint, Mich., the U.S. Environmental Protection Agency issued an emergency order Jan. 21 announcing it was taking over lead sampling in the city and that the EPA’s top Midwestern official would resign effective February 1.

While much of the criticism over how poisonous levels of lead leached into Flint’s water system has been directed at state and local officials, the federal agency charged with protecting citizens’ health also played a critical role in the disastrous chain of events.

In June 2015, Miguel del Toral, a regulations manager in the EPA’s ground water and drinking water branch, sent a memo to his agency superiors titled: High Lead Levels in Flint, Michigan – Interim Report. In it, del Toral stated that there were elevated levels of lead in several Flint homes after the city began using the Flint River as its municipal water source. In one home, the lead levels amounted to 13,200 parts per billion. The level that triggers federal action is 15. Del Toral also wrote that Flint lacked a plan to adequately prevent corrosion in the lead pipes that delivered water to the city of almost 100,000 people.

Read more: The Poisoning of an American City

By then, local residents had been complaining of rashes, hair loss and other ailments, and General Motors had stopped using Flint water at its local plant because it was corroding engine parts. Still, city and state officials continued to tell the public that Flint’s water was safe.

The EPA, however, did not act publicly on del Toral’s findings. Susan Hedman, the EPA administrator who resigned this week, has argued that her office could not legally make that information known. That claim was based on an interpretation of federal law that the EPA is responsible for establishing standards for states to follow, but doesn’t necessarily have the ability to force states to comply with those standards. As a result, Hedman says the EPA tried to apply behind-the-scenes pressure to get the Michigan Department of Environmental Quality to take action.

“Let’s be clear, the recommendation to DEQ (regarding the need for corrosion controls) occurred at higher and higher levels during this time period,” Hedman told the Detroit News on Jan. 12. She said Michigan officials rebuffed the EPA, insisting that such corrosion controls were not required by law. Hedman said she sought a legal opinion on whether the EPA could force the state’s hand, but it took months for an answer. (The EPA declined to make Hedman available to comment.) All the while, residents of Flint were drinking and bathing in toxic water.

Read more: Photographing Flint’s Water Crisis From the Inside

In December, a task force appointed by Republican Gov. Rick Snyder placed much of the blame for the water crisis on DEQ, leading its director to resign. Since then, Snyder declared a state of emergency and used his State of the State address on Jan. 22 to apologize for his response and announce $28.5 million in aid. On Jan. 21, President Obama announced an additional $80 million in federal emergency funds.

With Hedman’s resignation and the implementation of new policies designed to prevent future outbreaks of lead, the EPA is belatedly acknowledging its own missteps. Among the measures unveiled Thursday by EPA chief Gina McCarthy are two direct responses to the failures in Flint: a mechanism for the agency to force action in the face of “immediate and substantial” public health threats, and a more clearly defined way for whistle blowers like del Toral to bring problems to light.

Get The Brief. Sign up to receive the top stories you need to know right now. Please enter a valid email address. Sign Up Now Check the box if you do not wish to receive promotional offers via email from TIME. You can unsubscribe at any time. By signing up you are agreeing to our Terms of Use and Privacy Policy . This site is protected by reCAPTCHA and the Google Privacy Policy and Terms of Service apply. Thank you! For your security, we've sent a confirmation email to the address you entered. Click the link to confirm your subscription and begin receiving our newsletters. If you don't get the confirmation within 10 minutes, please check your spam folder.

Contact us at letters@time.com.