Skip to content

Commit

Permalink
Fix missing startupcheck if using token from file
Browse files Browse the repository at this point in the history
  • Loading branch information
Dielee committed Mar 15, 2024
1 parent 8f210c9 commit e85b2ef
Showing 1 changed file with 5 additions and 4 deletions.
9 changes: 5 additions & 4 deletions src/volvo.py
Original file line number Diff line number Diff line change
Expand Up @@ -92,14 +92,15 @@ def authorize(renew_tokenfile=False):
refresh_token = token_data["refresh_token"]

util.save_to_json(token_data)
get_vcc_api_keys()
get_vehicles()
check_supported_endpoints()
Thread(target=backend_status_loop).start()
else:
message = auth.json()
raise Exception(message["details"][0]["userMessage"])

get_vcc_api_keys()
get_vehicles()
check_supported_endpoints()
Thread(target=backend_status_loop).start()

def continue_auth(auth_session, data):
next_url = data["_links"]["continueAuthentication"]["href"] + "?action=continueAuthentication"
auth = auth_session.get(next_url)
Expand Down

0 comments on commit e85b2ef

Please sign in to comment.