Skip to content

Commit

Permalink
Ensure forceNewSession overload gets picked first (#138685)
Browse files Browse the repository at this point in the history
  • Loading branch information
joyceerhl committed Dec 9, 2021
1 parent b70174e commit ab80dae
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions src/vscode-dts/vscode.d.ts
Original file line number Diff line number Diff line change
Expand Up @@ -14148,9 +14148,9 @@ declare module 'vscode' {
* @param providerId The id of the provider to use
* @param scopes A list of scopes representing the permissions requested. These are dependent on the authentication provider
* @param options The {@link AuthenticationGetSessionOptions} to use
* @returns A thenable that resolves to an authentication session if available, or undefined if there are no sessions
* @returns A thenable that resolves to an authentication session
*/
export function getSession(providerId: string, scopes: readonly string[], options?: AuthenticationGetSessionOptions): Thenable<AuthenticationSession | undefined>;
export function getSession(providerId: string, scopes: readonly string[], options: AuthenticationGetSessionOptions & { forceNewSession: true | { detail: string } }): Thenable<AuthenticationSession>;

/**
* Get an authentication session matching the desired scopes. Rejects if a provider with providerId is not
Expand All @@ -14163,9 +14163,9 @@ declare module 'vscode' {
* @param providerId The id of the provider to use
* @param scopes A list of scopes representing the permissions requested. These are dependent on the authentication provider
* @param options The {@link AuthenticationGetSessionOptions} to use
* @returns A thenable that resolves to an authentication session
* @returns A thenable that resolves to an authentication session if available, or undefined if there are no sessions
*/
export function getSession(providerId: string, scopes: readonly string[], options: AuthenticationGetSessionOptions & { forceNewSession: true | { detail: string } }): Thenable<AuthenticationSession>;
export function getSession(providerId: string, scopes: readonly string[], options?: AuthenticationGetSessionOptions): Thenable<AuthenticationSession | undefined>;

/**
* An {@link Event} which fires when the authentication sessions of an authentication provider have
Expand Down

0 comments on commit ab80dae

Please sign in to comment.