Airbnb Inc. said it has agreed to drop a lawsuit against New York City challenging a law imposing penalties on people who post short-term apartment rentals in the company’s biggest U.S. market.

In exchange, regulators won’t seek to punish the company itself, said Linda Rosenthal, a state assembly member from Manhattan who has led the effort against Airbnb. Officials have said that the law was never intended to go after Airbnb directly anyway.

Rosenthal described the settlement as a full capitulation by the company. “This is an astounding about-face on the part of Airbnb, which clearly recognized that this was a foolhardy and frivolous lawsuit,” she said in an e-mailed statement.

>> Go Deeper: Airbnb Vs. New York City: The Complete Battle Up to Now

Peter Schottenfels, a spokesman for Airbnb, said the settlement will mark the first time the company would be working together with New York City to cut down on illegal activity. “We look forward to using this as a basis to finding an approach that protects responsible New Yorkers while cracking down on illegal hotels that remove permanent housing off the market or create unsafe spaces,” he wrote in an e-mail.

In October, just after the bill was passed by New York lawmakers, Airbnb proposed a new policy there called “one host, one home.” [Skift Editor’s Note: This policy was introduced by Airbnb prior to October 2016; Airbnb said it would enforce this policy just days before the law was signed by the governor.] It promised to help go after people who rent multiple apartments.

The state legislation punishes people advertising rentals of less than 30 days with fines of as much as $7,500. Airbnb sued to block the law just hours after it was signed on Oct. 21, claiming the restrictions are unconstitutional. A month later, Airbnb settled with New York state, with both sides agreeing that enforcement was up to the city.

Airbnb faces pressure from governments around the world, which say home rentals contribute to housing shortages and drive up prices for residents. The company sued San Francisco and other cities in California to block enforcement of their own laws that would penalize it for hosts’ activities on the site. Legal and regulatory questions remain a major hurdle for a potential initial public offering for Airbnb, which was valued at $30 billion by investors this year.

There’s still a difference of opinion about how the New York law should be enforced. Rosenthal said she expected the city to begin enforcement against “serial lawbreakers.” But it could also be used to punish anyone who lists their own apartment on the service, unless they are physically present during a guest’s stay. Airbnb said officials shouldn’t go after people who rent their primary residences.

The case is Airbnb Inc. v. Schneiderman, 16-cv-08239, U.S. District Court, Southern District of New York (Manhattan).

(Updates with Airbnb’s global regulatory battles in the sixth paragraph.)

With assistance from Bob Van Voris. To contact the reporter on this story: Joshua Brustein in New York at jbrustein@bloomberg.net. To contact the editors responsible for this story: Mark Milian at mmilian@bloomberg.net, Michael Hytha

©2016 Bloomberg L.P. This article was written by Joshua Brustein from Bloomberg and was legally licensed through the NewsCred publisher network.

Photo Credit: This New York rental listed on Airbnb is often used for fashion photoshoots, industry events and art shows. Airbnb dropped its opposition to a New York City law tightening restrictions on short-term rentals. Airbnb