Update to handle errors and display error messages from remote server