mirror of
https://github.com/microsoft/vscode.git
synced 2026-04-19 23:07:09 -05:00
Address feedback on auth provider API
This commit is contained in:
@@ -141,7 +141,12 @@ export class GitHubAuthenticationProvider {
|
||||
|
||||
private async tokenToSession(token: string, scopes: string[]): Promise<vscode.AuthenticationSession> {
|
||||
const userInfo = await this._githubServer.getUserInfo(token);
|
||||
return new vscode.AuthenticationSession(uuid(), token, { label: userInfo.accountName, id: userInfo.id }, scopes);
|
||||
return {
|
||||
id: uuid(),
|
||||
accessToken: token,
|
||||
account: { label: userInfo.accountName, id: userInfo.id },
|
||||
scopes
|
||||
};
|
||||
}
|
||||
|
||||
private async setToken(session: vscode.AuthenticationSession): Promise<void> {
|
||||
|
||||
Reference in New Issue
Block a user