SAN FRANCISCO (AP) — The California Supreme Court on Thursday sided with employers in a fight over the right of workers to sue over treatment for injuries that occur on the job.

Workers receiving medical care through the workers' compensation insurance of their employer generally cannot sue a doctor who decides whether treatment is needed, the court said in a unanimous decision.

The ruling came in the case of injured worker Kirk King, who says he suffered seizures after a doctor discontinued his anxiety medication.

The doctor was responsible for evaluating whether treatment prescribed for King after a back injury on the job was needed.

The justices said King had to pursue his claims against the doctor through a separate workers' compensation system set up by the Legislature, not through the courts.

An email to an attorney for King was not immediately returned.

At issue in the case were so-called utilization reviewers — physicians working on behalf of employers who have the power to modify, deny or delay treatment of an injured worker. The oversight is intended in part to reduce costs.

The California Chamber of Commerce and insurance groups had warned that a ruling in favor of King would open the door to additional lawsuits that would drive up employers' premiums for workers' compensation insurance.

The justices said barring suits against utilization review doctors and companies was consistent with the "basic trade-off" that underlies the system.

Workers get "swift and certain payments for medical treatment" in exchange for forfeiting their right to sue over their injuries, Associate Justice Leondra Kruger wrote for the court.

Kruger said the system created by the Legislature has safeguards to protect against wrongdoing by utilization reviewers, including the potential loss of their medical licenses.