File tree Expand file tree Collapse file tree 1 file changed +9
-2
lines changed Expand file tree Collapse file tree 1 file changed +9
-2
lines changed Original file line number Diff line number Diff line change @@ -223,8 +223,15 @@ export async function resolveConnectionSpec(serverName: string): Promise<void> {
223223export async function resolvePassword ( serverSpec ) : Promise < void > {
224224 const AUTHENTICATION_PROVIDER = "intersystems-server-credentials" ;
225225 // This arises if setting says to use authentication provider
226- if ( typeof serverSpec . password === "undefined" ) {
227- const scopes = [ serverSpec . name , serverSpec . username || "" ] ;
226+ if (
227+ // Connection isn't unauthenticated
228+ serverSpec . username != undefined &&
229+ serverSpec . username != "" &&
230+ serverSpec . username . toLowerCase ( ) != "unknownuser" &&
231+ // A password is missing
232+ typeof serverSpec . password == "undefined"
233+ ) {
234+ const scopes = [ serverSpec . name , serverSpec . username ] ;
228235 let session = await vscode . authentication . getSession ( AUTHENTICATION_PROVIDER , scopes , { silent : true } ) ;
229236 if ( ! session ) {
230237 session = await vscode . authentication . getSession ( AUTHENTICATION_PROVIDER , scopes , { createIfNone : true } ) ;
You can’t perform that action at this time.
0 commit comments