Photo: President Trump in 2020 on reopening schools.

HARRISBURG, Pa. (AP) — A federal judge has dismissed the Trump campaign’s longshot effort to block the certification of votes in Pennsylvania. The scathing order Saturday rejects the campaign’s claims of widespread irregularities with mail-in ballots.

The case had been President Donald Trump’s best hope to affect the election results through the courts, mostly because of the large number of electoral votes, 20, at stake in Pennsylvania.

The president’s legal team says it will appeal the decision and hopes to reach the U.S. Supreme Court in short order. Pennsylvania’s only Republican U.S. senator, Pat Toomey, says the ruling effectively ends Trump’s legal avenues in the state, and he congratulated President-elect Joe Biden on his victory.