mirror of
https://github.com/ansible-collections/community.general.git
synced 2024-09-14 20:13:21 +02:00
avoid returning nested list
This commit is contained in:
parent
b7d6c78808
commit
f6c4492c52
1 changed files with 3 additions and 6 deletions
|
@ -64,9 +64,9 @@ EXAMPLES = """
|
||||||
|
|
||||||
RETURN = """
|
RETURN = """
|
||||||
_raw:
|
_raw:
|
||||||
description: List containing the secret JSON object. Guaranteed to be of length 1.
|
description: List containing one or more secrets.
|
||||||
type: list
|
type: list
|
||||||
elements: raw
|
elements: dict
|
||||||
"""
|
"""
|
||||||
|
|
||||||
from subprocess import Popen, PIPE
|
from subprocess import Popen, PIPE
|
||||||
|
@ -112,10 +112,7 @@ class Bitwarden(object):
|
||||||
|
|
||||||
out, err = self._run(params)
|
out, err = self._run(params)
|
||||||
|
|
||||||
# This includes things that matched in different fields.
|
return AnsibleJSONDecoder().raw_decode(out)[0]
|
||||||
initial_matches = AnsibleJSONDecoder().raw_decode(out)[0]
|
|
||||||
|
|
||||||
return [initial_matches]
|
|
||||||
|
|
||||||
|
|
||||||
class LookupModule(LookupBase):
|
class LookupModule(LookupBase):
|
||||||
|
|
Loading…
Reference in a new issue