Merge pull request #8035 from zfalen-deloitte/bugfix/duplicate-backstage-token

Bugfix/duplicate backstage token
This commit is contained in:
Patrik Oldsberg
2021-11-15 11:50:17 +01:00
committed by GitHub
4 changed files with 15 additions and 5 deletions
@@ -49,7 +49,9 @@ const Component: ProviderComponent = ({ config, onResult }) => {
userId: identity!.id,
profile: profile!,
getIdToken: () => {
return authApi.getBackstageIdentity().then(i => i!.idToken);
return authApi
.getBackstageIdentity()
.then(i => i!.token ?? i!.idToken);
},
signOut: async () => {
await authApi.signOut();