Added and fixed z-validation.