mirror of
https://github.com/microsoft/vscode.git
synced 2025-12-27 13:40:25 +00:00
Use the tenantId property instead (#260418)
since it _seems_ most of the time, the idTokenClaims are not present.
This commit is contained in:
committed by
GitHub
parent
e2bf82fb5a
commit
86ff5cd43b
@@ -129,10 +129,7 @@ export class MsalAuthProvider implements AuthenticationProvider {
|
||||
// Send telemetry for existing accounts
|
||||
for (const cachedPca of this._publicClientManager.getAll()) {
|
||||
for (const account of cachedPca.accounts) {
|
||||
if (!account.idTokenClaims?.tid) {
|
||||
continue;
|
||||
}
|
||||
const tid = account.idTokenClaims.tid;
|
||||
const tid = account.tenantId;
|
||||
const type = tid === MSA_TID || tid === MSA_PASSTHRU_TID ? MicrosoftAccountType.MSA : MicrosoftAccountType.AAD;
|
||||
this._telemetryReporter.sendAccountEvent([], type);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user