The judge set to hear New York Attorney General Barbara Underwood’s lawsuit against Exxon Mobil Corp. has agreed to divest from his current stock in the gas and oil company and decline any restitution that may come from the case for investors.

Manhattan Supreme Court Justice Barry Ostrager of the Commercial Division said in court on Wednesday that he would sell his shares in the company—which amount to somewhere between $100,000 and $250,000 in one fund, and an unknown amount in a retirement account.