validation errors not working