18. Where, upon the trial of an election petition respecting an election, or upon petition to the Supreme Court by a candidate, the Election Judge, or a Judge of the Supreme Court, reports that a candidate at such election has been guilty by himself or his agents of the offence of treating or undue influence or of any illegal practice in reference to such election, and the Election Judge or Judge further reports, after giving the Attorney-General an opportunity of being heard, that the candidate has proved to the Election Judge or Judge-
(a) that no corrupt or illegal practice was committed at such election by the candidate and the offences mentioned in the said report were committed by other persons contrary to the orders and without the sanction or connivance of such candidate, and that such candidate took all reasonable means for preventing the commission of corrupt and illegal practices at such election; or
(b) that the offences mentioned in the said report were of a trivial, unimportant and limited character; or
(c) that the offences mentioned in the said report arose from inadvertence or from accidental miscalculation or from some other reasonable cause, and in any case did not arise from any want of good faith on the part of the candidate,
then the election of such candidate shall not, by reason of the offences mentioned in such report, be void, nor shall the candidate be subject to any incapacity of being registered as an elector or voting under this or any other Law.