Michael Cohen, known as a former lawyer for U.S. President Donald Trump, will be allowed to return to house arrest again. Cohen was transferred back to prison two weeks ago after he had already been released under house arrest.

New York Judge Alvin Hellerstein decided on Thursday local time to allow Cohen to return to house arrest because he estimated the return to prison was a retaliation that had turned out to be a Trump revelation book written by Cohen.

Before the judge's decision, Cohen's lawyers had argued that Cohen had been transit back to prison because he had not agreed to refrain from publishing the book. The book is said to present the president in a bad light.

According to Hellerstein, the condition imposed on Cohen was contrary to freedom of expression. The first amendment to the U.S. Constitution also protects citizens' freedom of expression with respect to publications.

He ordered Cohen to be released under house arrest in Manhattan, New York on Friday.

Cohen was initially placed under house arrest in May

Two weeks ago, the return of 53-year-old Cohen to prison was justified on the grounds that he had broken the rules of his house arrest.

Cohen served a three-year sentence in a federal prison in New York when he was placed under house arrest in late May. The release of Cohen from prison was linked to measures taken to prevent the spread of the coronavirus in prisons.

In December 2018, Cohen was sentenced to Congress for, among other things, lying and tax fraud.

Prior to his return to prison, the New York Post published pictures of Cohen at a restaurant in Manhattan.

Cohen's attorney, Jeffrey Levine, said at the time that Cohen was then presented with conditions related to house arrest. The conditions prohibited, for example, speaking to the press and publishing memoirs. Cohen was told at the time he planned to publish a book about Trump in the coming months.

According to authorities, Cohen refused to sign the terms. According to Cohen's defense, he would have agreed to the terms after he was threatened with return to prison.

The book reveals Trump’s use of power behind the scenes

According to Cohen’s lawyers, the memoirs written by the man contain graphically characterized details of Trump’s behavior behind closed doors. Cohen’s defense says, based on court documents, that the book provides descriptions of, among other things, anti-Semitic and racist comments.

Trump’s ex-lawyer defense said the president made racist comments about, among others, former President Barack Obama and the late South African president Nelson Mandela, who fought against racial segregation.

Cohen was at one point Trump’s runner-up, but he fell into disfavor after testifying against Trump in the federal courtroom as well as in the country’s Congress.

Cohen has pleaded guilty to a number of crimes, including violations of campaign finance laws. During the 2016 presidential election, he made payments to adult entertainment actor Stormy Daniels, who has said he was in a relationship with Trump before he ran for president.

The charges were allegedly intended to dampen Daniels. Trump has disputed the claims of the adult entertainment actor.