mirror of
https://github.com/ansible-collections/community.general.git
synced 2025-10-26 21:59:38 -07:00
module utils: update code to python3 (#10907)
* module utils: update code to python3 * add changelog frag
This commit is contained in:
parent
ce544f370c
commit
cc83188594
9 changed files with 83 additions and 77 deletions
|
|
@ -183,7 +183,7 @@ class UTM:
|
|||
result = None
|
||||
if response is not None:
|
||||
results = json.loads(response.read())
|
||||
result = next(iter(filter(lambda d: d['name'] == module.params.get('name'), results)), None)
|
||||
result = next(iter([d for d in results if d['name'] == module.params.get('name')]), None)
|
||||
return info, result
|
||||
|
||||
def _clean_result(self, result):
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue