security_groups can not be None

security_groups is a list variable, but the way to judge is
‘if security_groups is None’

this should be modified
Closes-Bug: #1749400

Change-Id: Idedf53e86f5edf6c88b3942f8a343021a6b53710
This commit is contained in:
JiWei 2018-02-14 17:16:10 +08:00
parent 15c4ba5011
commit d6b0a0060b
1 changed files with 1 additions and 1 deletions

View File

@ -284,7 +284,7 @@ def parse_floating_cpu(spec):
def get_security_group_ids(context, security_groups, **kwargs):
if security_groups is None:
if not security_groups:
return None
else:
neutron = clients.OpenStackClients(context).neutron()