SALEM, Ore. (AP) — A federal judge has ordered the U.S. Army Corps of Engineers to take immediate action to improve fish passage at dams in Oregon’s Willamette Basin.

In a final opinion and order issued this week, U.S. District Judge Marco Hernandez said the Corps had for years failed to provide adequate passage for threatened chinook salmon and winter steelhead at dams it operates in the basin.

The order comes after the court decided in favor of three environmental organizations that sued the Corps and the National Marine Fisheries Service, arguing the agencies weren’t doing their part to protect the species.