Skip to content

Commit

Permalink
py2-3 compatibility. Requests throws ValueError on json decoding errors
Browse files Browse the repository at this point in the history
  • Loading branch information
SenadI committed Apr 27, 2016
1 parent feaeb4c commit 924fe26
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion sevenbridges/decorators.py
Original file line number Diff line number Diff line change
Expand Up @@ -68,7 +68,7 @@ def wrapper(*args, **kwargs):
raise e
except requests.RequestException as e:
raise SbgError(message=str(e))
except json.JSONDecodeError as e:
except ValueError as e:
raise SbgError(message=str(e))

return wrapper

0 comments on commit 924fe26

Please sign in to comment.