Skip to content
This repository has been archived by the owner on Nov 14, 2024. It is now read-only.

Commit

Permalink
Fixing method name (#172)
Browse files Browse the repository at this point in the history
<!-- This change is generated by MagicModules. -->
/cc @rambleraptor
  • Loading branch information
modular-magician authored and rambleraptor committed May 20, 2019
1 parent 2298a07 commit e57f827
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions lib/ansible/modules/cloud/google/gcp_sourcerepo_repository.py
Original file line number Diff line number Diff line change
Expand Up @@ -185,8 +185,8 @@ def return_if_object(module, response, allow_not_found=False):
try:
module.raise_for_status(response)
result = response.json()
except getattr(json.decoder, 'JSONDecodeError', ValueError) as inst:
module.fail_json(msg="Invalid JSON response with error: %s" % inst)
except getattr(json.decoder, 'JSONDecodeError', ValueError):
module.fail_json(msg="Invalid JSON response with error: %s" % response.text)

if navigate_hash(result, ['error', 'errors']):
module.fail_json(msg=navigate_hash(result, ['error', 'errors']))
Expand Down

0 comments on commit e57f827

Please sign in to comment.