🐛 Fix issue when refreshing OAuth2 credentials (Hubspot) (#1489)

This commit is contained in:
Ricardo Espinoza 2021-02-25 02:05:52 -05:00 committed by GitHub
parent 61903efaed
commit 85703a8bf7
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -44,7 +44,7 @@ export async function hubspotApiRequest(this: IHookFunctions | IExecuteFunctions
return await this.helpers.request!(options);
} else {
// @ts-ignore
return await this.helpers.requestOAuth2!.call(this, 'hubspotOAuth2Api', options, { tokenType: 'Bearer' });
return await this.helpers.requestOAuth2!.call(this, 'hubspotOAuth2Api', options, { tokenType: 'Bearer', includeCredentialsOnRefreshOnBody: true });
}
} catch (error) {
let errorMessages;