The Supreme Court granted that request in September but did not give its reasoning until Wednesday.

The Minnesota Supreme Court ruled Wednesday that state Democrats had the authority to put another nominee's name on the ballot after Rep. Kerry Gauthier announced he would not seek re-election for his Duluth-area legislative seat.

Gauthier, the party's original nominee, withdrew his bid for re-election in August after he admitted he had a sexual encounter with a 17-year-old boy. Democrats asked to have Gauthier removed from the ballot and be replaced with Erik Simonson, who planned to run as a write-in candidate.

The Supreme Court granted that request in September but did not give its reasoning until Wednesday. Simonson, a Duluth assistant fire chief, defeated Republican Travis Silvers in the November election.

In a 21-page opinion, justices wrote that state law gives a major political party the authority to fill a nominee vacancy for any partisan office if the original nominee has withdrawn in accordance with state law. The justices wrote that a vacancy occurs when a candidate dies or follows proper procedures for withdrawal.

The court also found that the St. Louis County auditor erred when he did not accept both Gauthier's affidavit for withdrawal and the party's certificate nominating Simonson.

Attorneys for St. Louis County auditor Donald Dicklich and Secretary of State Mark Ritchie argued that a vacancy in nomination occurs only when a candidate for constitutional office — not legislative office — files an affidavit of withdrawal.

The Supreme Court disagreed. If that argument was correct, the court said, then nonpartisan candidates could withdraw from a race only in the event of their death — and candidates in many races, other than those for executive branch constitutional offices, must keep their names on the ballot even if they withdraw.

"Respondents' proposed interpretation has the potential to lead to an absurd result," the Supreme Court said in its ruling.

"To limit the ability of candidates for non-constitutional offices to withdraw from the general election ballot due only to death leads to the possibility of multiple elections for one seat," the justices wrote. "For example, if the withdrawn nominee wins the election, a special election immediately becomes necessary to allow voters to once again choose their elected representative."

In a separate opinion, the Supreme Court also explained why it did not allow write-in candidate Jay Fosle's name to appear on the ballot.

Fosle had opposed the effort to list Simonson's name on the ballot unless his was also added as an "independent candidate" or without party affiliation. The justices ruled that his request had no statutory basis, saying there was no evidence he was endorsed by the Independence Party and he did not file a petition to be placed on the ballot without a party nomination.

Fosle also argued he had the constitutional right to equal protection under law because he and Simonson were both initially write-in candidates. But the Supreme Court found that once the Democratic-Farmer-Labor Party nominated Simonson, he and Fosle were no longer in the same situation, so that argument failed.