U.S. Bankruptcy Judge Steven Rhodes was halfway through reading his 48-page decision approving Detroit’s reorganization plan on Nov. 7 when Honigman Miller Schwartz & Cohn’s Arthur O’Reilly began choking up.

O’Reilly was in the courtroom as the Detroit Institute of Arts’ lead litigator. The city’s July 2013 bankruptcy filing had raised the specter that some or all of the DIA’s collection would be sold off, and O’Reilly had spent the better part of two years preparing the city-owned museum for possible litigation if the city attempted to do so. But the plan Judge Rhodes signed off on—the so-called Grand Bargain, in which the museum commits to raise $100 million of $816 million in donations and state appropriations over 20 years to benefit the city’s retirees—was an outcome he couldn’t have imagined 18 months earlier. In transferring title to a new nonprofit entity, the judge ensured that the DIA’s 60,037-piece collection would forever be beyond the reach of the city and its potential creditors.