From 459601c8e770f81576e852413e3007ccea640ba0 Mon Sep 17 00:00:00 2001 From: Till Maas Date: Wed, 11 Jul 2018 10:06:45 +0200 Subject: [PATCH] Fail when trying to down a non-existing NM profile --- library/network_connections.py | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/library/network_connections.py b/library/network_connections.py index b77ad3f..02e330d 100644 --- a/library/network_connections.py +++ b/library/network_connections.py @@ -2661,9 +2661,10 @@ class Cmd_nm(Cmd): self.log_error(idx, 'down connection failed while waiting: %s' % (e)) cons = self.nmutil.connection_list(name = connection['name']) - if not changed: - self.log_info(idx, 'down connection %s failed: no connection' % (connection['name'])) + self.log_error(idx, + 'down connection %s failed: connection not found' % + (connection['name'])) ###############################################################################