Change idempotency check to be single pass (#42087)
- Previously all data between both data structures was compared - Results in situations where updates are done when not needed - Changes to single pass so only data in payload is compared
This commit is contained in:
parent
09fec5a482
commit
3ee3fc893d
1 changed files with 8 additions and 8 deletions
|
@ -130,14 +130,14 @@ class MerakiModule(object):
|
|||
if not optional_ignore:
|
||||
optional_ignore = ('')
|
||||
|
||||
for k, v in original.items():
|
||||
try:
|
||||
if k not in ignored_keys and k not in optional_ignore:
|
||||
if v != proposed[k]:
|
||||
is_changed = True
|
||||
except KeyError:
|
||||
if v != '':
|
||||
is_changed = True
|
||||
# for k, v in original.items():
|
||||
# try:
|
||||
# if k not in ignored_keys and k not in optional_ignore:
|
||||
# if v != proposed[k]:
|
||||
# is_changed = True
|
||||
# except KeyError:
|
||||
# if v != '':
|
||||
# is_changed = True
|
||||
for k, v in proposed.items():
|
||||
try:
|
||||
if k not in ignored_keys and k not in optional_ignore:
|
||||
|
|
Loading…
Reference in a new issue