Repository: libcloud Updated Branches: refs/heads/trunk d9f1abde1 -> 33b96f81a
cloudstack: If no volumes are found return an empty list Closes #617 Signed-off-by: Tomaz Muraus <[email protected]> Project: http://git-wip-us.apache.org/repos/asf/libcloud/repo Commit: http://git-wip-us.apache.org/repos/asf/libcloud/commit/0306394b Tree: http://git-wip-us.apache.org/repos/asf/libcloud/tree/0306394b Diff: http://git-wip-us.apache.org/repos/asf/libcloud/diff/0306394b Branch: refs/heads/trunk Commit: 0306394b668c256671583148dba1118de745943a Parents: d9f1abd Author: Wido den Hollander <[email protected]> Authored: Wed Oct 28 15:03:26 2015 +0100 Committer: Tomaz Muraus <[email protected]> Committed: Mon Nov 2 15:46:47 2015 +0100 ---------------------------------------------------------------------- libcloud/compute/drivers/cloudstack.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) ---------------------------------------------------------------------- http://git-wip-us.apache.org/repos/asf/libcloud/blob/0306394b/libcloud/compute/drivers/cloudstack.py ---------------------------------------------------------------------- diff --git a/libcloud/compute/drivers/cloudstack.py b/libcloud/compute/drivers/cloudstack.py index 3c4b243..0d06786 100644 --- a/libcloud/compute/drivers/cloudstack.py +++ b/libcloud/compute/drivers/cloudstack.py @@ -2168,8 +2168,9 @@ class CloudStackNodeDriver(CloudStackDriverMixIn, NodeDriver): method='GET') list_volumes = [] + extra_map = RESOURCE_EXTRA_ATTRIBUTES_MAP['volume'] - for vol in volumes['volume']: + for vol in volumes.get('volume', []): extra = self._get_extra_dict(vol, extra_map) if 'tags' in vol:
