fix form field validation