Libraries refactor and add some sinks #4

Closed
m wants to merge 136 commits from library-refactor into master
1 changed files with 3 additions and 3 deletions
Showing only changes of commit 87dccc1cf4 - Show all commits

View File

@ -83,9 +83,9 @@ class Revolut(object):
settings.Revolut.RefreshToken = parsed["refresh_token"]
settings.Revolut.SetupToken = "0"
settings.write()
self.log.info("Refreshed refresh token: {refresh_token}", refresh_token=settings.Revolut.RefreshToken)
self.log.info("Refreshed refresh token")
self.token = parsed["access_token"]
self.log.info("Refreshed access token: {access_token}", access_token=self.token)
self.log.info("Refreshed access token")
except KeyError:
self.log.error(f"Token authorization didn't contain refresh or access token: {parsed}", parsed=parsed)
return False
@ -119,7 +119,7 @@ class Revolut(object):
if r.status_code == 200:
if "access_token" in parsed.keys():
self.token = parsed["access_token"]
self.log.info("Refreshed access token: {access_token}", access_token=self.token)
self.log.info("Refreshed access token")
return True
else:
self.log.error(f"Token refresh didn't contain access token: {parsed}", parsed=parsed)