Skip to content

Commit f882339

Browse files
committed
Correct indentation of ACL comparator
Only check for missing wanted ACLs after processing all had ACLs, not just the first one. Addresses ansible-collections#512
1 parent ba877b2 commit f882339

File tree

1 file changed

+17
-17
lines changed
  • plugins/module_utils/network/eos/config/acls

1 file changed

+17
-17
lines changed

Diff for: plugins/module_utils/network/eos/config/acls/acls.py

+17-17
Original file line numberDiff line numberDiff line change
@@ -278,23 +278,23 @@ def _state_replaced(self, want, have):
278278
config_cmds.append(
279279
list(itertools.chain(*cmds)),
280280
)
281-
if name not in ace_names:
282-
for w_ace in want_ace:
283-
w = [
284-
{
285-
"afi": afi,
286-
"acls": [
287-
{
288-
"name": name,
289-
"aces": [w_ace],
290-
},
291-
],
292-
},
293-
]
294-
cmds = set_commands(w, have)
295-
config_cmds.append(
296-
list(itertools.chain(*cmds)),
297-
)
281+
if name not in ace_names:
282+
for w_ace in want_ace:
283+
w = [
284+
{
285+
"afi": afi,
286+
"acls": [
287+
{
288+
"name": name,
289+
"aces": [w_ace],
290+
},
291+
],
292+
},
293+
]
294+
cmds = set_commands(w, have)
295+
config_cmds.append(
296+
list(itertools.chain(*cmds)),
297+
)
298298

299299
if remove_cmds:
300300
remove_cmds = list(itertools.chain(*remove_cmds))

0 commit comments

Comments
 (0)