An El Paso discrimination case that began three years ago with two men kissing in a restaurant has come to an end after a settlement calling for diversity training for the city’s police officers was reached.

The settlement with the city was announced Monday by Carlos Diaz de Leon and his lawyers at City Hall, ABC-7 in El Paso reports.

The agreement calls for the city to fund annual police diversity training on LGBT issues. The security company that works at the restaurant will also train its employees on diversity and sensitivity.

Diaz de Leon, along with four other unnamed men, filed a lawsuit in 2010 against the city, Chico’s Taco and a security company after they were thrown out by security in June 2009 when two of the men kissed in the restaurant. They were also threatened with charges under Texas’ sodomy statute by El Paso police who were misinformed that the statute was declared unconstitutional by the U.S. Supreme Court in 2003.

The case spurred a response by the El Paso City Council, which had already approved an ordinance banning discrimination based on sexual orientation by businesses in 2003. Later in 2009 the council approved domestic partner benefits for unmarried gay and straight couples, but they were overturned in a ballot measure led by El Paso Pastor Tom Brown in 2010.

The council voted to restore the benefits in 2011, prompting Brown to start a recall effort. A county judge ruled in Brown’s favor in a battle with El Paso Mayor John Cook but a court of appeals overturned the decision in February. Brown then appealed to the Texas Supreme Court.

Police later admitted to making a mistake in threatening charges, citing police officer Israel Rodriguez-Aceves’ rookie status for his misguided threats. Rodriguez-Aceves later wrote an apology letter as part of the case. Released Monday, it reads: “I am writing you to state that I regret the way the situation was handled that evening. From this point on, as a police officer, I will enforce the city’s anti-discrimination ordinance.”

Diaz de Leon told ABC-7 that the outcome was “a step forward, not only for the gay community but the straight community as well.”