[chrome-gnome-shell] connector: fixed TypeError exception



commit 7fee37e38805e5b4b9f0d02d7e5c7da95d63450f
Author: Yuri Konotopov <ykonotopov gnome org>
Date:   Mon Feb 6 11:20:55 2017 +0400

    connector: fixed TypeError exception

 connector/chrome-gnome-shell.py |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)
---
diff --git a/connector/chrome-gnome-shell.py b/connector/chrome-gnome-shell.py
index ac6740a..9a88790 100755
--- a/connector/chrome-gnome-shell.py
+++ b/connector/chrome-gnome-shell.py
@@ -534,7 +534,7 @@ class ChromeGNOMEShell(Gio.Application):
                     requests.ConnectionError, requests.HTTPError, requests.Timeout,
                     requests.TooManyRedirects, requests.RequestException, ValueError
                     ) as ex:
-                error_message = str(ex.message) if ('message' in ex) else str(ex)
+                error_message = str(ex.message) if hasattr(ex, 'message') else str(ex)
                 log_error('Unable to check extensions updates: %s' % error_message)
 
                 request_url = ex.response.url if ex.response is not None else ex.request.url


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]