mirror of
https://github.com/ansible-collections/community.general.git
synced 2026-05-06 21:32:49 +00:00
multiple modules: improve dict.items() loops (#8876)
* multiple modules: improve dict.items() loops * simplify in memset_* modules * add changelog frag
This commit is contained in:
@@ -277,9 +277,9 @@ class GitLabGroup(object):
|
||||
changed = False
|
||||
|
||||
for arg_key, arg_value in arguments.items():
|
||||
if arguments[arg_key] is not None:
|
||||
if getattr(group, arg_key) != arguments[arg_key]:
|
||||
setattr(group, arg_key, arguments[arg_key])
|
||||
if arg_value is not None:
|
||||
if getattr(group, arg_key) != arg_value:
|
||||
setattr(group, arg_key, arg_value)
|
||||
changed = True
|
||||
|
||||
return (changed, group)
|
||||
|
||||
Reference in New Issue
Block a user