Fix validation error where required is skipped.