From dcee274ebba96bdf1bb18972b8975039dd0fd7eb Mon Sep 17 00:00:00 2001 From: Hiroaki Nakamura Date: Tue, 5 Jul 2016 21:34:27 +0900 Subject: [PATCH] Fix initializing err in _get_err_from_resp_json --- cloud/lxd/__init__.py | 1 + 1 file changed, 1 insertion(+) diff --git a/cloud/lxd/__init__.py b/cloud/lxd/__init__.py index 23161ef6312..46b2fda6ed9 100644 --- a/cloud/lxd/__init__.py +++ b/cloud/lxd/__init__.py @@ -124,6 +124,7 @@ class LXDClient(object): @staticmethod def _get_err_from_resp_json(resp_json): + err = None metadata = resp_json.get('metadata', None) if metadata is not None: err = metadata.get('err', None)