Allow to take down connections if not in config

Allow to take down connections regardless of whether they are defined in
the configuration. It should be enough that the connection is defined on
the system.
This commit is contained in:
Till Maas 2018-05-19 00:03:01 +02:00
parent d370966ee2
commit 756be9a8de

View file

@ -1120,7 +1120,7 @@ class ArgValidator_ListConnections(ArgValidatorList):
def _validate_post(self, value, name, result):
for idx, connection in enumerate(result):
if connection['state'] in ['down', 'up']:
if connection['state'] in ['up']:
if connection['state'] == 'up' and 'type' in connection:
pass
elif not ArgUtil.connection_find_by_name(connection['name'], result, idx):