mirror of
https://github.com/microsoft/vscode.git
synced 2026-04-26 03:29:00 +01:00
clearSessionPreference works again + test. Fixes #137615
This commit is contained in:
@@ -251,7 +251,9 @@ export class MainThreadAuthentication extends Disposable implements MainThreadAu
|
||||
throw new Error('User did not consent to login.');
|
||||
}
|
||||
|
||||
const session = await this.authenticationService.createSession(providerId, scopes, true);
|
||||
const session = sessions?.length && !options.forceNewSession
|
||||
? await this.authenticationService.selectSession(providerId, extensionId, extensionName, scopes, sessions)
|
||||
: await this.authenticationService.createSession(providerId, scopes, true);
|
||||
await this.setTrustedExtensionAndAccountPreference(providerId, session.account.label, extensionId, extensionName, session.id);
|
||||
return session;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user