Bank accounts held by President Donald Trump were closed by Capital One in 2021 after it flagged financial activity that had characteristics of money laundering, the bank disclosed in a court filing over the weekend.

The court filing is tied to a lawsuit filed against Capital One by one of Trump’s financial holding companies shortly after he was sworn into office a second time. Trump alleges that Capital One illegally closed his accounts for political reasons, following the Jan. 6 attacks on the U.S. Capitol.

Capital One wants the lawsuit dismissed.

“The closures were the result of months of analysis and a careful review by Capital One’s AML team in accordance with bank policies and regulatory guidance,” the bank said in the court filing. The term “AML” is an abbreviation for anti-money laundering.

Trump has sued Capital One, as well as JPMorgan Chase, for allegedly debanking him after he left office in 2021. Debanking occurs when banks shut down customer accounts because they believe they pose financial, legal or reputational risks to the banks.