Target is getting closer to closing the book on its Canadian debacle.

The Minneapolis-based retailer cleared a major hurdle by reaching a settlement Friday with the landlords of the 133 stores in Canada it shuttered last year.

In January, a Canadian judge in Ontario Superior Court had struck down the company’s previous proposal, which some landlords had objected to, saying that Target Corp. was not fulfilling its original promise to cover future losses in the event of store closures.

Under the amended plan Target Canada announced late last week, landlords will get 66 to 77 percent of their claims.

“This agreement is the result of months of tough negotiations with stakeholders,” Aaron Alt, the chief executive of Target Canada, said in a statement. “We are delighted to have achieved a consensual path forward and believe that the Amended Plan is in the best interests of the stakeholders of Target Canada. We remain focused on achieving a timely wind-down of the [court] proceedings, and distributing proceeds to stakeholders as soon as possible.”

The Globe and Mail newspaper, citing unnamed industry sources, reported the new settlement requires the Minneapolis parent company to throw in an extra $30 million or so to cover landlords’ claims.

A Target spokeswoman said she could not share details, but noted that the financial impact of the settlement is “materially consistent” with what the company has previously recorded in its financial statements.

In January 2015, Target began shutting its Canadian operations less than two years after they opened, in what was the retailer’s first expansion beyond the U.S. The stores racked up about $2 billion in losses as they grappled with stocking and pricing issues that turned off Canadian consumers.

Target Chief Executive Brian Cornell, five months into the job at the time, decided the company should cut its losses, close the 133 stores and let go of 17,600 employees.

If all goes according to plan, Target hopes to get final court approval of its Canadian wind-down plan on June 2.