Corrected missing return keyword in CustomValidator class