aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/plugins/action/parse_json_file.py
diff options
context:
space:
mode:
Diffstat (limited to 'plugins/action/parse_json_file.py')
-rwxr-xr-xplugins/action/parse_json_file.py8
1 files changed, 4 insertions, 4 deletions
diff --git a/plugins/action/parse_json_file.py b/plugins/action/parse_json_file.py
index d9c864a..fe776a8 100755
--- a/plugins/action/parse_json_file.py
+++ b/plugins/action/parse_json_file.py
@@ -11,8 +11,8 @@ class ActionModule(ActionBase):
def run(self, tmp=None, task_vars=None):
result = super().run(tmp, task_vars)
- path = self._task.args['path']
- default = self._task.args.get('default')
+ path = self._task.args["path"]
+ default = self._task.args.get("default")
if default is not None:
default = json.dumps(default)
@@ -21,7 +21,7 @@ class ActionModule(ActionBase):
try:
content = json.loads(content)
except json.JSONDecodeError as e:
- raise AnsibleActionFail(f'Failed to parse JSON at {path}') from e
+ raise AnsibleActionFail(f"Failed to parse JSON at {path}") from e
- result['content'] = content
+ result["content"] = content
return result