Added code to catch validation errors