finished validations and error alerts