Whenever in any contested nomination or election, the tribunal trying the case shall decide that the ballots or ballot labels used in one or more election districts, by reason of the omission, addition, misplacing, misspelling or misstatement of one or more titles of office, or names of candidates, or parties or bodies represented by them, were so defective as to the office in contest as to be calculated to mislead the voters in regard to any of the candidates nominated or seeking nomination for said office, and that the defective condition of the said ballots or ballot labels may have affected the result of the entire primary or election for said office, the said tribunal shall declare the primary or election to be invalid as regards the said office, and in the case of elections shall report their decision, in cases where vacancies in such offices are filled by appointment, to the proper officer or officers who are by law authorized to fill vacancies occurring in such office, who, upon receipt of such notice, shall, without delay, proceed to appoint a suitable person or persons to fill the vacancies thus created, and the person or persons so appointed shall continue in office until the next election succeeding his appointment at which such office is by law required to be filled. All other vacancies so created shall be filled in such manner as now or hereafter may be provided by law, and all vacancies in nominations so created shall be filled in the manner provided by section 979 of this act.
25 P.S. § 3472