error handling for invalid phone numbers