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:
parent
15c4ba5011
commit
d6b0a0060b
|
@ -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()
|
||||
|
|
Loading…
Reference in New Issue