mirror of https://github.com/actions/toolkit
payload updated
parent
c7ec4073b7
commit
1c86c4c890
|
@ -45,11 +45,11 @@ export class OidcClient {
|
|||
|
||||
private static async postCall(httpclient: actions_http_client.HttpClient, id_token_url: string, audience: string): Promise<string> {
|
||||
|
||||
const data : TokenRequest = { aud : !!audience ? '{aud: audience}' : undefined }
|
||||
const data :TokenRequest = { aud: !!audience ? audience : ''}
|
||||
|
||||
debug(`audience is ${audience !== null ? audience : 'null'}`)
|
||||
debug(`audience is ${!!audience ? audience : 'not defined'}`)
|
||||
|
||||
const res = await httpclient.postJson<TokenResponse>(id_token_url,data.aud).catch((error) => {
|
||||
const res = await httpclient.postJson<TokenResponse>(id_token_url,data).catch((error) => {
|
||||
throw new Error(
|
||||
`Failed to get ID Token. \n
|
||||
Error Code : ${error.statusCode}\n
|
||||
|
|
Loading…
Reference in New Issue