CHICAGO (AP) — A federal judge overseeing former U.S. Rep. Aaron Schock's political corruption case has tossed a charge alleging the Illinois Republican illegally pocketed thousands of dollars in leftover fees constituents paid for annual meet-and-greets in Washington organized by his office.

The ruling, posted late Monday, dismissed two counts and left 22 other, still-serious charges. But Schock's attorney suggested Tuesday that Judge Colin Bruce's finding buttresses his contention that the overall case against Schock is flimsy.

"What we described ... in earlier pleadings as a house of cards has begun to fall," George Terwilliger said in an emailed statement.

The U.S. attorney's office in Springfield declined comment.

The 51-page ruling highlights the separation of powers between the executive, legislative and judicial branches in the U.S. Constitution. It said there are risks Schock's prosecution could violate that longstanding principle, which is meant to ensure the independence of each branch.

Prosecutors had alleged that dozens of constituents at a time paid a "Fly-in Conference Fee" of $500 or more to Schock's office to cover meals, transportation and other hosting costs. Filings accused Schock of secretly keeping at least $11,000 from one 2014 event.

But to prove the Schock, 36, of Peoria, broke the law by keeping the fees, the Urbana-based judge said prosecutors would have to rely too much on imprecise U.S. House rules and expect the judge to glean what lawmakers had in mind by drawing up the rules as they did.

"This is something which the court may not do," he wrote.

The judge also dismissed one count of theft of government funds on grounds it bundled too many alleged crimes into a single charge. The remaining counts are eight of wire fraud, five of falsification of election commission filings, six of filing false income tax returns, two of making false statements and one of mail fraud.

"There are still ample counts for the prosecution," explained Jeff Cramer, a former federal prosecutor who is now a Chicago-based managing director of investigations at Berkeley Research Group. "The prosecution really needs just one count to get to a sentencing,"

A conviction on just one wire fraud count carries a maximum 20-year prison term.

Among the allegations that remain are that Schock illegally sought reimbursement in government funds for lavish spending, including $5,000 on a chandelier for his Washington office, which he was redecorating in the style of the "Downton Abbey" TV series.

Schock resigned in 2015 and was indicted in 2016. He has pleaded not guilty and is scheduled to go to trial on Jan. 22.

Judge Bruce didn't find that prosecutors rely too much on House rules when it came to allegations Schock ran up a $140,000 mileage tab over six years, reimbursements for 150,000 more miles than his vehicles actually traveled. Bruce concluded such an alleged fraud could potentially be proven without reference to legislative rules.

But he added that he could revisit that finding and toss more counts as details emerge in government evidence.