Skip to content

Commit

Permalink
Merge pull request #86 from alandtse/#HA37106
Browse files Browse the repository at this point in the history
Address HA report #37106
  • Loading branch information
alandtse committed Jun 26, 2020
2 parents e1534b9 + 1d4c107 commit d40c8f3
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion teslajsonpy/__version__.py
Original file line number Diff line number Diff line change
Expand Up @@ -6,4 +6,4 @@
https://github.com/zabuldon/teslajsonpy
"""

__version__ = "0.8.0"
__version__ = "0.8.1"
2 changes: 1 addition & 1 deletion teslajsonpy/connection.py
Original file line number Diff line number Diff line change
Expand Up @@ -154,7 +154,7 @@ async def __open(
_LOGGER.debug("%s: %s", resp.status, json.dumps(data))
if resp.status > 299:
if resp.status == 401:
if data.get("error") == "invalid_token":
if data and data.get("error") == "invalid_token":
raise TeslaException(resp.status, "invalid_token")
elif resp.status == 408:
raise TeslaException(resp.status, "vehicle_unavailable")
Expand Down

0 comments on commit d40c8f3

Please sign in to comment.