diff options
Diffstat (limited to 'cinderclient/v3')
| -rw-r--r-- | cinderclient/v3/group_snapshots.py | 2 | ||||
| -rw-r--r-- | cinderclient/v3/groups.py | 10 |
2 files changed, 3 insertions, 9 deletions
diff --git a/cinderclient/v3/group_snapshots.py b/cinderclient/v3/group_snapshots.py index ed7fe79..9225995 100644 --- a/cinderclient/v3/group_snapshots.py +++ b/cinderclient/v3/group_snapshots.py @@ -96,7 +96,7 @@ class GroupSnapshotManager(base.ManagerWithFind): :param search_opts: search options :rtype: list of :class:`GroupSnapshot` """ - query_string = utils.build_query_param(search_opts) + query_string = utils.build_query_param(search_opts, sort=True) detail = "" if detailed: diff --git a/cinderclient/v3/groups.py b/cinderclient/v3/groups.py index c042e28..e42f750 100644 --- a/cinderclient/v3/groups.py +++ b/cinderclient/v3/groups.py @@ -14,8 +14,6 @@ # under the License. """Group interface (v3 extension).""" -from six.moves.urllib import parse - from cinderclient import api_versions from cinderclient.apiclient import base as common_base from cinderclient import base @@ -140,11 +138,7 @@ class GroupManager(base.ManagerWithFind): :rtype: :class:`Group` """ query_params = utils.unicode_key_value_to_string(kwargs) - - query_string = "" - if query_params: - params = sorted(query_params.items(), key=lambda x: x[0]) - query_string = "?%s" % parse.urlencode(params) + query_string = utils.build_query_param(query_params, sort=True) return self._get("/groups/%s" % group_id + query_string, "group") @@ -159,7 +153,7 @@ class GroupManager(base.ManagerWithFind): if not search_opts: search_opts = {} search_opts['list_volume'] = True - query_string = utils.build_query_param(search_opts) + query_string = utils.build_query_param(search_opts, sort=True) detail = "" if detailed: |
