From 8528c2a2f117e4caa85f3392c2381a2bf529dc12 Mon Sep 17 00:00:00 2001 From: Jan Oberhauser Date: Sun, 13 Dec 2020 17:33:43 +0100 Subject: [PATCH] :bug: Fix issue that GitHub OAuth did not use specified server --- .../nodes-base/credentials/GithubOAuth2Api.credentials.ts | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/packages/nodes-base/credentials/GithubOAuth2Api.credentials.ts b/packages/nodes-base/credentials/GithubOAuth2Api.credentials.ts index 6625f81a00..ed5238353b 100644 --- a/packages/nodes-base/credentials/GithubOAuth2Api.credentials.ts +++ b/packages/nodes-base/credentials/GithubOAuth2Api.credentials.ts @@ -23,14 +23,14 @@ export class GithubOAuth2Api implements ICredentialType { displayName: 'Authorization URL', name: 'authUrl', type: 'hidden' as NodePropertyTypes, - default: 'https://github.com/login/oauth/authorize', + default: '={{$parameter["server"] === "https://api.github.com" ? "https://github.com" : $parameter["server"]}}/login/oauth/authorize', required: true, }, { displayName: 'Access Token URL', name: 'accessTokenUrl', type: 'hidden' as NodePropertyTypes, - default: 'https://github.com/login/oauth/access_token', + default: '={{$parameter["server"] === "https://api.github.com" ? "https://github.com" : $parameter["server"]}}/login/oauth/access_token', required: true, }, {