The judge says the government cannot force insurance companies to pay the cost of leaving