The New York Police Department expressed willingness to compromise on a package of bills that would make sweeping changes to a decades-old law it has called a cornerstone of quality-of-life policing.

During a City Council hearing Wednesday on 13 bills that would reform the way the NYPD carries out its nuisance abatement actions, Assistant Commissioner Robert Messner said the tool is critical for providing “direct and immediate relief” to neighborhoods affected by crime. Still, he said, the NYPD “is supportive of the concepts behind many of these proposals, and more broadly the goal of reforming” the law.

City Council Speaker Melissa Mark-Viverito and several other Council members introduced the Nuisance Abatement Fairness Act in response to an investigation by ProPublica and the New York Daily News that exposed widespread abuse of the law.

The city enacted the law in 1977 to combat the sex industry in Times Square during its heyday as a red-light district. The police have since used the law to fight other vices, such as unruly clubs, drug trafficking, gambling, and, more recently, the sale of synthetic marijuana known as K2.

But the ProPublica/Daily News analysis of 1,162 cases filed during an 18-month period beginning in 2013 found the NYPD also frequently sought closures of homes over low-level drug charges — some of which were ultimately dismissed — and bodegas accused of selling beer to underage auxiliary officers.

Messner said the NYPD is willing to remove marijuana possession as a charge that could lead to an action, to shorten the time frame within which a case must be brought, and to refrain from using sealed criminal cases in its filings.

He also said the department backs a bill to mandate lab reports to support drug allegations, but opposes a measure that would increase the required number of drug sales to four from three, saying it would force officers to orchestrate another purchase after a search warrant has been executed, putting them and confidential informants at risk.

Among the most controversial elements of the law is its provision for ex parte orders — the legal term for an order sought in court without the other party present. ProPublica and the Daily News found the NYPD had requested ex parte orders to close down a location in nearly every case.

The NYPD has since amended its ex parte practices, seeking closing orders less frequently and tailoring most of its requests in residential cases to exclude only “individuals arrested within the subject premises within the past year and any and all persons acting individually or in concert with them.”

The Council is proposing to eliminate ex parte orders altogether.

NYPD Deputy Commissioner Lawrence Byrne said the department would be willing to codify the changes it has already made, but “would want to draft language that would allow us to use them in narrow circumstances.”

Byrne said he also supports a measure to limit exclusions of people from homes to one year, or three in the most egregious cases.

He noted the NYPD has significantly reduced the number of nuisance cases it has filed overall — from 2,609 between 2013 and 2015, to 307 between January and October of this year.

Mark-Viverito said conversations with the NYPD have been productive. “I think it’s really clear that this is a law that has been in place for many, many years and it’s a bit outdated, and we need to fine-tune it,” she said.