validate the text fields so they cant be empty