WASHINGTON — The Supreme Court on Tuesday put a hold on a lower court ruling that said election officials in Pennsylvania must count mail-in ballots from voters who failed to fill in the date on their ballot envelopes.

The appeals court ruling was a decision that could affect the outcome of the undecided Senate Republican primary in the Keystone State.

Less than 950 votes separate celebrity doctor Mehmet Oz, who is backed by former President Donald Trump, and former hedge fund executive David McCormick. That tally does not include at least 860 disputed mail ballots. Folding those ballots into a recount now underway, one required by law because of the closeness of the vote, could determine the GOP’s nominee for November.

McCormick is asking a federal court to rule that the undated ballots must be counted, but the Supreme Court’s order Tuesday came in a different disputed election, for a state judgeship in 2021. In that contest, Republican David Ritter led Democrat Zac Cohen by 71 votes. That total did not include mail-in votes submitted without the date required by state law on the outer envelope.

A Pennsylvania law provides that ballots cast by mail must be placed in a pre-printed envelope, which the voter must “fill out, date, and sign.” After a state court ruled that undated ballots should not be counted in the judicial election, a group of voters went to federal court, arguing that the ballots should be counted.

The U.S. Court of Appeals for the 3rd Circuit, based in Philadelphia, ruled that a provision of the federal Civil Rights Act requires votes to be counted even if they contain minor errors that are not material to determining whether the person casting the ballot is legally qualified to vote.

Pennsylvania’s attorney general has determined that a mail ballot must be counted even if the date written on the envelope is the wrong one. Therefore, the appeals court said, “If the substance of the string of numbers does not matter, then it is hard to understand how one could claim that this requirement has any use in determining a voter’s qualifications.”

In asking the Supreme Court to put that ruling on hold, Ritter called the materiality provision part of “an obscure federal statute” and said the appeals court’s reasoning is a “green light to federal courts to rewrite dozens of state election laws around the country.”

Requirements such as signing and dating a ballot help ensure election integrity “given the heightened risk of fraud post by mail-in voting,” he said.

Republicans addressed their request to Justice Samuel Alito, who handles appeals from that region. He put a hold on the appeals court ruling while the Supreme Court considers how to rule on the emergency appeal.