A Beverly Hills police chief is at the center of an ugly, costly and lengthy legal battle after the wealthy city agreed to pay $2.3 million to settle a lawsuit brought by a former high-ranking police officer amid an onslaught of other allegations.

Chief Sandra Spagnoli, a self-described “change agent,” was hired in 2016 and lavished with praise from the city’s mayor and council members, as well as Vogue magazine, for aggressive reforms, but now she faces accusations of misconduct herself.

Spagnoli is accused of referring to yarmulkes worn by observant Jews as “funny little hats,” asked if she had to “dress Mexican” when invited to a meal at a Latino employee’s home, and reacted with revulsion when she was informed that an employee was gay. Other court documents contain allegations that Spagnoli had sex with subordinate officers who were later rewarded with promotions, according to the Los Angeles Times.

Capt. Mark Rosen, who is Jewish, accused Spagnoli of harassment and workplace misconduct, denying him promotional opportunities based on his religion.

Rosen immediately retired after the $2.3 million suit was settled in December, but said he fears for his colleagues.

“I am concerned for my co-workers I am leaving behind, the officers and civilians alike who continue to be victimized,” Rosen said.

Spagnoli faces at least 20 civil suits or employee complaints of racial and sexual discrimination, according to court records.

She has repeatedly denied the allegations, characterizing them as pushback to her efforts to change the agency.

“I’m disappointed at some of the personal attacks against me, particularly because I can tell you I love this community. I love being a key factor in public safety and making a difference,” she said. “It hasn’t been easy running the department while under fire from different directions.”

The decision to settle Rosen’s lawsuit was made by the city’s insurance company, according to a spokesman.

The Associated Press contributed to this report.