Michael Cohen, Donald Trump‘s former attorney and fixer, will return to home confinement in Manhattan after his lawyers filed a lawsuit against his imprisonment.

Cohen, who was sentenced to three years in prison for breaking campaign finance laws, committing tax fraud and lying to Congress, had been released from federal prison in May along with some other inmates over COVID-19 health concerns. The house arrest allowed him a lot of leeway, and he was active on social media, promoting his upcoming tell-all book on Trump.

However, on July 9 he was taken back to prison in Otisville, New York, for supposedly violating a clause that forbade him from speaking with the media. The American Civil Liberties Union (ACLU) and Cohen’s lwayers, argued that this was a restriction of Cohen’s First Amendment right to free speech.

Judge Alvin Hellerstein agreed.

“He was put on furlough with no conditions other than hang around your house and be in your neighborhood,” said Hellerstein. “All of a sudden when the New York Post article comes out and the Bureau of Prisons understands he’s writing a book, and it’ll be finished by election time, they impose conditions.”

Hellerstein also stated that it was an unusual clause to begin with.

This was not the first time that Trump and his supporters tried to stop books about the president from being published. Exposés about Trump have been a popular genre recently, with the president’s niece Mary Trump‘s Too Much and Never Enough and former national security adviser John Bolton‘s The Room Where It Happened. However, the attempts to prevent the publication of these books has not been successful. On July 1, courts ruled in favor of the publication of Mary Trump’s book.

As for Cohen’s own work, he tweeted that its “anticipated release date will be late September.”