Skip to content

Commit

Permalink
Correct indentation of ACL comparator
Browse files Browse the repository at this point in the history
Only check for missing wanted ACLs after processing all had ACLs, not
just the first one.  Addresses ansible-collections#512
  • Loading branch information
bewing committed Dec 30, 2024
1 parent ba877b2 commit f882339
Showing 1 changed file with 17 additions and 17 deletions.
34 changes: 17 additions & 17 deletions plugins/module_utils/network/eos/config/acls/acls.py
Original file line number Diff line number Diff line change
Expand Up @@ -278,23 +278,23 @@ def _state_replaced(self, want, have):
config_cmds.append(
list(itertools.chain(*cmds)),
)
if name not in ace_names:
for w_ace in want_ace:
w = [
{
"afi": afi,
"acls": [
{
"name": name,
"aces": [w_ace],
},
],
},
]
cmds = set_commands(w, have)
config_cmds.append(
list(itertools.chain(*cmds)),
)
if name not in ace_names:
for w_ace in want_ace:
w = [
{
"afi": afi,
"acls": [
{
"name": name,
"aces": [w_ace],
},
],
},
]
cmds = set_commands(w, have)
config_cmds.append(
list(itertools.chain(*cmds)),
)

if remove_cmds:
remove_cmds = list(itertools.chain(*remove_cmds))
Expand Down

0 comments on commit f882339

Please sign in to comment.