WASHINGTON — A federal court has struck down a 2018 Agriculture Department rule that reversed nutrition standards for sodium and whole grains in school meal programs once championed by the former first lady Michelle Obama.

The U.S. District Court for the District of Maryland vacated the rule, concluding that it violated the Administrative Procedure Act because the 2018 rule differed significantly from the administration’s 2017 interim rule setting up the final standards. The school breakfast and lunch rule is only the latest in a series of Trump administration regulations that have been struck down for violating the legal procedures that Congress set out for approving new regulations.

“The court concludes that the rule is not inconsistent with federal law, it does not reflect unexplained and arbitrary decision making, it does not represent an unacknowledged and unexplained change in position, and the U.S.D.A. appropriately responded to public comments,” ruled U.S. District Judge George J. Hazel, a nominee of President Barack Obama. “The court does find, however, that the final rule is not a logical outgrowth of the interim final rule, so it must be vacated.”

The Agriculture Department said it does not comment on ongoing litigation.

The ruling comes as most schools have been shut down for more than a month because of the coronavirus pandemic. Many school meal providers are struggling to get meals to children with grab-and-go sites or handouts along school bus routes. Such difficulties were not addressed by the ruling.