fix: add headers for refresh token

This commit is contained in:
ikechan8370 2023-05-06 01:11:19 +08:00 committed by GitHub
parent 6485d7a93e
commit e47f18a5aa
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -1930,7 +1930,10 @@ export class chatgpt extends plugin {
refresh_token: Config.OpenAiPlatformRefreshToken,
client_id: 'DRivsnm2Mu42T3KOpqdtwB3NYviHYzwD',
grant_type: 'refresh_token'
})
}),
headers: {
'Content-Type': 'application/json'
}
})
if (refreshRes.status !== 200) {
let errMsg = await refreshRes.json()