summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorGary Rybak <grybak@arista.com>2016-06-14 10:09:23 -0600
committerGary Rybak <grybak@arista.com>2016-06-14 10:09:23 -0600
commitdc21c211e36edaee95657c31baca0878e0b91ada (patch)
treea85ad1566157de94b6da1cdcce56635a08dbea76
parent0802569af99ab08ccacd149e06cffe7f8dac872a (diff)
downloadansible-modules-core-dc21c211e36edaee95657c31baca0878e0b91ada.tar.gz
Move call to filter_exit out of command execution block
to prevent setting 'changed' on a command list that is completely filtered (empty).
-rw-r--r--network/eos/eos_template.py2
1 files changed, 1 insertions, 1 deletions
diff --git a/network/eos/eos_template.py b/network/eos/eos_template.py
index 550d3bad..924268dc 100644
--- a/network/eos/eos_template.py
+++ b/network/eos/eos_template.py
@@ -192,8 +192,8 @@ def main():
else:
commands = str(candidate).split('\n')
+ commands = filter_exit(commands)
if commands:
- commands = filter_exit(commands)
if not module.check_mode:
commands = [str(c).strip() for c in commands]
response = module.configure(commands, replace=replace)