Implementing logic to show message on server error.