adding error alert