Skip to content

Commit dd1ca68

Browse files
committed
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
1 parent a207c27 commit dd1ca68

1 file changed

Lines changed: 13 additions & 9 deletions

File tree

openstackclient/compute/v2/server.py

Lines changed: 13 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -37,7 +37,7 @@
3737
from openstackclient.common import utils
3838
from openstackclient.i18n import _ # noqa
3939
from openstackclient.identity import common as identity_common
40-
from openstackclient.network import common
40+
from openstackclient.network import common as network_common
4141

4242

4343
def _format_servers_list_networks(networks):
@@ -476,15 +476,19 @@ def take_action(self, parsed_args):
476476
if neutron_enabled:
477477
network_client = self.app.client_manager.network
478478
if nic_info["net-id"]:
479-
nic_info["net-id"] = common.find(network_client,
480-
'network',
481-
'networks',
482-
nic_info["net-id"])
479+
nic_info["net-id"] = network_common.find(
480+
network_client,
481+
'network',
482+
'networks',
483+
nic_info["net-id"]
484+
)
483485
if nic_info["port-id"]:
484-
nic_info["port-id"] = common.find(network_client,
485-
'port',
486-
'ports',
487-
nic_info["port-id"])
486+
nic_info["port-id"] = network_common.find(
487+
network_client,
488+
'port',
489+
'ports',
490+
nic_info["port-id"]
491+
)
488492
else:
489493
if nic_info["net-id"]:
490494
nic_info["net-id"] = utils.find_resource(

0 commit comments

Comments
 (0)