Skip to content

Commit

Permalink
fix: comparison of two lists with different length
Browse files Browse the repository at this point in the history
closes #9
  • Loading branch information
lucasheld committed Nov 6, 2022
1 parent 69332a7 commit a608cc5
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion plugins/module_utils/common.py
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ def object_changed(superset, subset, ignore=None):
if not value2:
changed_keys.append((key, superset.get(key), subset[key]))
elif type(value[i]) == list or type(value[i]) == dict:
if object_changed(value2[i], value[i]):
if i >= len(value2) or object_changed(value2[i], value[i]):
changed_keys.append((key, superset.get(key), subset[key]))
else:
if value[i] != value2[i]:
Expand Down

0 comments on commit a608cc5

Please sign in to comment.