Skip to content

Commit

Permalink
Remove debug logging
Browse files Browse the repository at this point in the history
  • Loading branch information
dan-r committed Dec 29, 2023
1 parent 09182d1 commit 3f0ea9d
Showing 1 changed file with 1 addition and 3 deletions.
4 changes: 1 addition & 3 deletions custom_components/ohme/api_client.py
Original file line number Diff line number Diff line change
Expand Up @@ -57,9 +57,8 @@ async def async_refresh_session(self):

# Don't refresh token unless its over 45 mins old
if time() - self._token_birth < 2700:
_LOGGER.warning((time() - self._token_birth))
return
_LOGGER.warning("Starting token refresh.")

async with self._auth_session.post(
f"https://securetoken.googleapis.com/v1/token?key={GOOGLE_API_KEY}",
data={"grantType": "refresh_token",
Expand All @@ -75,7 +74,6 @@ async def async_refresh_session(self):
self._token_birth = time()
self._token = resp_json['id_token']
self._refresh_token = resp_json['refresh_token']
_LOGGER.warning("Very nice, great success.")
return True


Expand Down

0 comments on commit 3f0ea9d

Please sign in to comment.