In yet another turn in a legal battle that has plagued President Donald Trump for months, Michael Cohen, his longtime fixer, offered late Friday to tear up a nondisclosure agreement with a pornographic film star who has long claimed she had an affair with Trump.

It remained unclear why Cohen made the abrupt move to scrap the hush-money deal with the star, Stormy Daniels. But one effect of voiding the arrangement would be that it could spare Trump the embarrassment of having to give a deposition in a lawsuit related to the case.

In a letter dated Sept. 7, Cohen’s lawyer, Brent H. Blakely, wrote to Daniels’ lawyer, Michael Avenatti, saying that Cohen had agreed “to accept the rescission” of the deal, which was reached in October 2016, a month before the presidential election.

Under the terms of the arrangement, Essential Consultants LLC, a shell company Cohen created, paid Daniels $130,000 not to speak publicly about a sexual relationship she said she began with Trump in 2006 after they met at a celebrity golf tournament in Nevada.

Shortly after the letter was filed in U.S. District Court in Los Angeles, Avenatti accused Cohen on Twitter of “playing games and trying to protect Donald Trump.”

Cohen is “now pulling a legal stunt to try and ‘fix it’ so that we can’t depose Trump and present evidence to the American people about what happened,” Avenatti said.

Blakely, who is based in Los Angeles, did not immediately respond to efforts to reach him, but in an interview Saturday morning, Avenatti insisted that the offer was “dead on arrival.”

Avenatti noted that even though Cohen had offered to rescind the deal, Trump had not extended a similar proposal. Avenatti added that he would accept the offer only if both Cohen and Trump acknowledged that the nondisclosure deal was illegal from the start because it violated federal campaign finance laws.

Last month, Cohen admitted to precisely that, acknowledging in a guilty plea in a Manhattan federal courtroom that he had broken campaign finance laws in structuring the deal with Clifford. In his plea, Cohen said he had struck the arrangement not only at Trump’s request but also to influence the election.