![](https://nordot-res.cloudinary.com/c_limit,w_800,f_auto,q_auto:eco/ch/images/1185592495426339681/origin_1.jpg)
Miami (AFP) - A Florida judge appointed by Donald Trump has dismissed the criminal case against the former president on charges of mishandling top secret documents, saying the way that Special Counsel Jack Smith was appointed was improper.
The decision is a huge victory for Trump, who had been accused of endangering national security by holding onto top secret documents after leaving the White House.
Judge Aileen Cannon made her ruling after lawyers for the 78-year-old argued for a partial stay of proceedings to allow for an assessment of a Supreme Court ruling that a former president has broad immunity from prosecution.
"Former President Trump's Motion to Dismiss Indictment Based on the Unlawful Appointment and Funding of Special Counsel Jack Smith is GRANTED," Aileen wrote in her order.
"The Superseding Indictment is DISMISSED because Special Counsel Smith's appointment violates the Appointments Clause of the United States Constitution."
It comes as Trump is set to be annointed as his party's champion at the Republican National Convention, days after surviving an assassination attempt at a rally in Pennsylvania.
In the Florida case, Trump was facing 31 counts of "willful retention of national defense information," each punishable by up to 10 years in prison.
He also faced charges of conspiracy to obstruct justice and making false statements.
Trump allegedly kept classified documents -- which included records from the Pentagon and CIA -- unsecured at his Mar-a-Lago home and thwarted efforts to retrieve them.