President Trump talked about quashing stories about his alleged affairs in the days leading up to the 2016 presidential election, according to documents unsealed in the Michael Cohen case Thursday.

A federal judge in Manhattan unsealed records showing the president was involved in discussions about how to keep the stories of alleged affairs with women including adult film actress Stormy Daniels and former Playboy model Karen McDougal from being published.

U.S. District Judge William Pauley ruled that the documents be unsealed, after prosecutors concluded their investigation related to the hush money payments and Cohen's campaign finance violations. Cohen is currently serving three years in federal prison.

Get Breaking News Delivered to Your Inbox

Mr. Trump initially denied knowledge of the payments. Asked in April 2018 if he knew about the payment Cohen made to adult film actress Stormy Daniels, Mr. Trump responded, "No," and, "You'll have to ask Michael Cohen."

But the newly unsealed records make clear he was aware of the frenetic efforts to keep silent both women in the days ahead of the election.

Trump attorney Jay Sekulow insisted in a statement Wednesday ahead of the document release that the closing of the Cohen probe exonerates the president.

Cohen, however, reiterated his claim that Mr. Trump had directed him to handle the Stormy Daniels payment.

"Jay Sekulow's statement is completely distorted and dishonest," Cohen said in a statement. "As I stated in my opening testimony, I and members of The Trump Organization were directed by Mr. Trump to handle the Stormy Daniels matter; including making the hush money payment. The conclusion of the investigation exonerating The Trump Organization's role should be of great concern to the American people and investigated by Congress and The Department of Justice."