A driver hit by a woman impaired by opioid medications administered by a hospital emergency room doctor less than two hours before the accident can sue the doctor and the hospital because they failed to warn the patient that driving would be hazardous, a divided Court of Appeals ruled Wednesday.

The 4-2 ruling in Davis v. South Nassau Communities Hospital, 163, extends physician liability to third-party plaintiffs “for failing to warn that medications administered would impair the patient’s driving ability,” Judge Eugene Fahey said in the majority opinion.