Cleaning up details
Signed-off-by: Olivier Liechti <olivier.liechti@wasabi-tech.com>
This commit is contained in:
@@ -29,9 +29,6 @@ describe('Strategy', () => {
|
||||
},
|
||||
() => {},
|
||||
);
|
||||
console.log(strategy.name);
|
||||
expect(strategy).toBeInstanceOf(Strategy);
|
||||
|
||||
expect((strategy as any).name).toBe('atlassian');
|
||||
} catch (e) {
|
||||
console.error(e);
|
||||
|
||||
@@ -70,7 +70,6 @@ export const atlassianAuthenticator = createOAuthAuthenticator<
|
||||
baseURL: baseUrl,
|
||||
authorizationURL: `${baseUrl}/authorize`,
|
||||
tokenURL: `${baseUrl}/oauth/token`,
|
||||
// profileURL: `${baseUrl}/api/v4/user`,
|
||||
profileURL: 'https://api.atlassian.com/me',
|
||||
scope: config.getOptionalString('additionalScopes')?.split(' ') || [],
|
||||
},
|
||||
@@ -81,14 +80,9 @@ export const atlassianAuthenticator = createOAuthAuthenticator<
|
||||
fullProfile: PassportProfile & { email: string; photo: string },
|
||||
done: PassportOAuthDoneCallback,
|
||||
) => {
|
||||
const fullProfileWithEmails = {
|
||||
...fullProfile,
|
||||
// avatarUrl: fullProfile.photo,
|
||||
// emails: [{ value: fullProfile.email }],
|
||||
};
|
||||
done(
|
||||
undefined,
|
||||
{ fullProfile: fullProfileWithEmails, params, accessToken },
|
||||
{ fullProfile, params, accessToken },
|
||||
{ refreshToken },
|
||||
);
|
||||
},
|
||||
|
||||
Reference in New Issue
Block a user