Skip to content

Commit 660a32a

Browse files
authored
remove id_token from flow (#2915)
1 parent 587b265 commit 660a32a

1 file changed

Lines changed: 4 additions & 4 deletions

File tree

packages/modules/vehicles/skoda/libskoda.py

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -104,7 +104,7 @@ async def reconnect(self):
104104
payload = {
105105
'client_id': CLIENT_ID,
106106
'scope': _scope,
107-
'response_type': 'code id_token',
107+
'response_type': 'code',
108108
'nonce': secrets.token_urlsafe(12),
109109
'redirect_uri': 'myskoda://redirect/login/',
110110
'state': str(uuid.uuid4()),
@@ -154,11 +154,11 @@ async def reconnect(self):
154154
while (True):
155155
url = response.headers['Location']
156156
if (url.split(':')[0] == "myskoda"):
157-
if not ('id_token' in url):
158-
self.log.error("Missing id token")
157+
if not ('code' in url):
158+
self.log.error("Missing authorization code")
159159
return False
160160
# Parse query string
161-
query_string = url.split('#')[1]
161+
query_string = url.split('?')[1]
162162
query = {x[0]: x[1] for x in [x.split("=") for x in query_string.split("&")]}
163163
break
164164

0 commit comments

Comments
 (0)