summaryrefslogtreecommitdiff
path: root/cinderclient/v3/pools.py
diff options
context:
space:
mode:
authorxianming mao <xianming.mao@easystack.cn>2016-12-01 20:18:26 +0800
committerxianming mao <xianming.mao@easystack.cn>2016-12-01 20:24:29 +0800
commit8a4f61a93d70a108ba1ca6739de019168afb0b6d (patch)
treec23cb8c5893135e3340428c5111805bdc4db9d8a /cinderclient/v3/pools.py
parentb8ed0c2d2729188a38fb0fb6b43e9ef6332709b7 (diff)
downloadpython-cinderclient-8a4f61a93d70a108ba1ca6739de019168afb0b6d.tar.gz
Replace six.iteritems(iter) with iter.items()
As mentioned in [1], we should avoid using six.iteritems(iter) to achieve iterators. We can use iter.items() instead, as it will return iterators in PY3 as well. [1] http://lists.openstack.org/pipermail/openstack-dev/2015-June/066391.html Change-Id: Ic41abf2ca6ec3ecb651b980091b52d0a185c9089
Diffstat (limited to 'cinderclient/v3/pools.py')
-rw-r--r--cinderclient/v3/pools.py4
1 files changed, 1 insertions, 3 deletions
diff --git a/cinderclient/v3/pools.py b/cinderclient/v3/pools.py
index 2f72605..5303f84 100644
--- a/cinderclient/v3/pools.py
+++ b/cinderclient/v3/pools.py
@@ -15,8 +15,6 @@
"""Pools interface (v3 extension)"""
-import six
-
from cinderclient import base
@@ -45,7 +43,7 @@ class PoolManager(base.Manager):
# be attributes of the pool itself.
for pool in pools:
if hasattr(pool, 'capabilities'):
- for k, v in six.iteritems(pool.capabilities):
+ for k, v in pool.capabilities.items():
setattr(pool, k, v)
# Remove the capabilities dictionary since all of its