strip keys recursively
This commit is contained in:
parent
7346e3098a
commit
61f05c2e8d
1 changed files with 2 additions and 0 deletions
|
@ -83,6 +83,8 @@ def strip_internal_keys(dirty):
|
||||||
for k in dirty.keys():
|
for k in dirty.keys():
|
||||||
if isinstance(k, string_types) and k.startswith('_ansible_'):
|
if isinstance(k, string_types) and k.startswith('_ansible_'):
|
||||||
del clean[k]
|
del clean[k]
|
||||||
|
elif isinstance(dirty[k], dict):
|
||||||
|
clean[k] = strip_internal_keys(dirty[k])
|
||||||
return clean
|
return clean
|
||||||
|
|
||||||
class VariableManager:
|
class VariableManager:
|
||||||
|
|
Loading…
Reference in a new issue