Fix issue with form validation