A federal judge today accused the state of “sleight of hand,” and halted plans to end welfare benefits to nearly 41,000 Michigan residents.

U.S. District Judge Paul Borman determined after a hearing today that the state failed to give proper notice to those it planned to cut off, and although the issue was brought to the federal court in a lawsuit filed by just three plaintiffs, the judge also granted class status to include everyone affected by the state’s decision.

Lawyers for the government declined to discuss after the hearing how the state will respond.

The judge’s order requires the state to send new notices to all those affected — and this time the state must include a copy of a new policy that dictates the changes.

Borman said it was unfair that the new policy wasn’t made public until Oct. 1, long after those effected were required to file protests.