PHILADELPHIA (AP) — Employers in Philadelphia cannot ask job applicants for their salary history, a federal appeals court ruled Thursday.

The 3rd U.S. Circuit Court of Appeals partially reversed a lower court’s 2018 decision that said the city could not ban employers from asking about salary history but could ban them from using it to determine wages.

The Greater Philadelphia Chamber of Commerce sued the city after the law was passed in 2017, saying the law would violate employers’ First Amendment rights to ask potential hires about their salary history.

Supporters of the law have said that since women have historically been paid less than men, the practice of asking for a salary history can help perpetuate a cycle of lower salaries for women.

In Judge Theodore McKee’s decision, he wrote that the provision does limit employers’ speech, but that it is “only because that limitation prevents the tentacles of any past wage discrimination from attaching to an employee’s subsequent salary.”

Several cities and states have passed similar legislation including New York City, Massachusetts and New Jersey.