mirror of
https://github.com/ckaczor/azuredatastudio.git
synced 2026-01-18 01:25:37 -05:00
Connection management service updates to support multiple providers (#9698)
* Connection management service work * Fix tests * Change how accounts are deleted * Be consistent with names * feedback * Fix based on feedback * Change sqltoolsservice version
This commit is contained in:
@@ -780,9 +780,9 @@ export class ConnectionManagementService extends Disposable implements IConnecti
|
||||
return true;
|
||||
}
|
||||
let azureResource = this.getAzureResourceForConnection(connection);
|
||||
let accounts = await this._accountManagementService.getAccountsForProvider('azurePublicCloud');
|
||||
let accounts = (await this._accountManagementService.getAccounts()).filter(a => a.key.providerId.startsWith('azure'));
|
||||
if (accounts && accounts.length > 0) {
|
||||
let accountName = (connection.authenticationType !== Constants.azureMFA) ? connection.azureAccount : connection.userName;
|
||||
let accountName = (connection.authenticationType === Constants.azureMFA) ? connection.azureAccount : connection.userName;
|
||||
let account = find(accounts, account => account.key.accountId === accountName);
|
||||
if (account) {
|
||||
if (account.isStale) {
|
||||
|
||||
Reference in New Issue
Block a user