If any person is challenged as being unqualified when offering to vote at any township election or upon any question arising at any township meeting is challenged as unqualified relating to a person's residency, the judges, or township clerk, if no judges are present, shall proceed thereupon in like manner as the judges at the general election are required to proceed, adapting the oath to the circumstances of the township meeting must have the person sign an affidavit attesting to the person's residency and qualification to vote. A person who makes a false affirmation is guilty of a Class 2 misdemeanor. 22