r, any money, reward or other valuable consideration for his vote at an election, or for withholding the same, shall thereby forfeit the right to vote at such election, and any elector whose right to vote shall be challenged for such cause before the election officers, shall be required to swear or affirm that the matter of the challenge is untrue before his vote shall be received.