Overturning Roe v. Wade doesn't undo a law. The problem is there's no law in the first place. It overturns a precedent. It's the judicial branch's equivalent of countermanding an Executive Order with a new Executive Order.
If it were a law, it'd never get to the courts in the first place.