Address review comments
Signed-off-by: Olivier Liechti <olivier.liechti@wasabi-tech.com>
This commit is contained in:
@@ -1,5 +0,0 @@
|
||||
---
|
||||
'@backstage/plugin-auth-backend': patch
|
||||
---
|
||||
|
||||
Use new Atlassian Passport profile in type definition
|
||||
@@ -1,6 +1,5 @@
|
||||
---
|
||||
'@backstage/plugin-auth-backend-module-atlassian-provider': patch
|
||||
'@backstage/plugin-auth-node': patch
|
||||
---
|
||||
|
||||
Fix issues with Atlassian OAuth provider
|
||||
Fix issues with Atlassian OAuth provider: retrieve the email and photo that were not in arrays but rather in single props.
|
||||
|
||||
@@ -40,10 +40,8 @@ export class PassportHelpers {
|
||||
if (profile.emails && profile.emails.length > 0) {
|
||||
const [firstEmail] = profile.emails;
|
||||
email = firstEmail.value;
|
||||
}
|
||||
|
||||
// This is the case for Atlassian
|
||||
if (profile.email) {
|
||||
} else if (profile.email) {
|
||||
// This is the case for Atlassian
|
||||
email = profile.email;
|
||||
}
|
||||
|
||||
@@ -54,7 +52,8 @@ export class PassportHelpers {
|
||||
const [firstPhoto] = profile.photos;
|
||||
picture = firstPhoto.value;
|
||||
} else if (profile.photo) {
|
||||
picture = profile.photo; // This is the case for Atlassian
|
||||
// This is the case for Atlassian
|
||||
picture = profile.photo;
|
||||
}
|
||||
|
||||
let displayName: string | undefined =
|
||||
|
||||
Reference in New Issue
Block a user