MIAMI (CBSMiami/AP) — A long-standing federal court case over the treatment of homeless people in Miami has finally come to an end with a settlement.

The city and the American Civil Liberties Union announced Thursday that the agreement had been filed with a federal judge after 23 hours of mediation.

The city in September sought to modify a 1998 court order that protected the homeless from police harassment, having their property destroyed, and many other provisions.

The ACLU says the agreement keeps in place the most important protections for Miami’s homeless. The settlement also puts a two-year moratorium on any further attempted modifications of the agreement to allow a “housing first” program a chance to succeed.

The original lawsuit was filed to end what proponents said was Miami’s practice of treating the homeless as criminals.