diff options
| author | Tang Chen <tangchen@cn.fujitsu.com> | 2015-12-06 01:18:13 +0800 |
|---|---|---|
| committer | Tang Chen <tangchen@cn.fujitsu.com> | 2015-12-06 01:18:13 +0800 |
| commit | dd1ca68f56b0a3631ca4bb682c0c0ae8cc4215ae (patch) | |
| tree | df0a9212030f04c32e18fb425fa4d0b782624225 /openstackclient | |
| parent | a207c27fc87595d8f59bb29436b7ccb2243a5682 (diff) | |
| download | python-openstackclient-dd1ca68f56b0a3631ca4bb682c0c0ae8cc4215ae.tar.gz | |
Trivial: Import network.common as network_common in server.py
In server.py, identity.common is imported as identity_common.
But network.common is imported as common, which is confuseing.
This patch imports network.common as network_common.
Change-Id: I74295bc88b22de398ab64fe556aedaca2453d17d
Diffstat (limited to 'openstackclient')
| -rw-r--r-- | openstackclient/compute/v2/server.py | 22 |
1 files changed, 13 insertions, 9 deletions
diff --git a/openstackclient/compute/v2/server.py b/openstackclient/compute/v2/server.py index d58ebacd..ee650700 100644 --- a/openstackclient/compute/v2/server.py +++ b/openstackclient/compute/v2/server.py @@ -37,7 +37,7 @@ from openstackclient.common import parseractions from openstackclient.common import utils from openstackclient.i18n import _ # noqa from openstackclient.identity import common as identity_common -from openstackclient.network import common +from openstackclient.network import common as network_common def _format_servers_list_networks(networks): @@ -476,15 +476,19 @@ class CreateServer(show.ShowOne): if neutron_enabled: network_client = self.app.client_manager.network if nic_info["net-id"]: - nic_info["net-id"] = common.find(network_client, - 'network', - 'networks', - nic_info["net-id"]) + nic_info["net-id"] = network_common.find( + network_client, + 'network', + 'networks', + nic_info["net-id"] + ) if nic_info["port-id"]: - nic_info["port-id"] = common.find(network_client, - 'port', - 'ports', - nic_info["port-id"]) + nic_info["port-id"] = network_common.find( + network_client, + 'port', + 'ports', + nic_info["port-id"] + ) else: if nic_info["net-id"]: nic_info["net-id"] = utils.find_resource( |
