Check item is one of six.string_types not just str
Change-Id: I343d9f6bdb3509256191a44e686f24e0ebeb5d22 Closes-Bug: #1762612
This commit is contained in:
@@ -13,6 +13,7 @@
|
|||||||
# WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
|
# WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
|
||||||
# License for the specific language governing permissions and limitations
|
# License for the specific language governing permissions and limitations
|
||||||
# under the License.
|
# under the License.
|
||||||
|
import six
|
||||||
|
|
||||||
|
|
||||||
def add_all_projects_option(parser):
|
def add_all_projects_option(parser):
|
||||||
@@ -70,5 +71,5 @@ def set_all_common_headers(client, parsed_args):
|
|||||||
set_edit_managed(client, parsed_args.edit_managed)
|
set_edit_managed(client, parsed_args.edit_managed)
|
||||||
|
|
||||||
if parsed_args.sudo_project_id is not None and \
|
if parsed_args.sudo_project_id is not None and \
|
||||||
isinstance(parsed_args.sudo_project_id, str):
|
isinstance(parsed_args.sudo_project_id, six.string_types):
|
||||||
set_sudo_project_id(client, parsed_args.sudo_project_id)
|
set_sudo_project_id(client, parsed_args.sudo_project_id)
|
||||||
|
@@ -70,8 +70,6 @@ class ListZonesCommand(command.Lister):
|
|||||||
client = self.app.client_manager.dns
|
client = self.app.client_manager.dns
|
||||||
common.set_all_common_headers(client, parsed_args)
|
common.set_all_common_headers(client, parsed_args)
|
||||||
|
|
||||||
common.set_all_common_headers(client, parsed_args)
|
|
||||||
|
|
||||||
criterion = {}
|
criterion = {}
|
||||||
if parsed_args.type is not None:
|
if parsed_args.type is not None:
|
||||||
criterion["type"] = parsed_args.type
|
criterion["type"] = parsed_args.type
|
||||||
|
Reference in New Issue
Block a user