mirror of
https://github.com/ckaczor/azuredatastudio.git
synced 2026-01-24 09:35:37 -05:00
Remove typings and replace missing methods with vscodes (#8217)
* remove typings and replace missing methods with vscodes * fix strict-null-checks * fix tests
This commit is contained in:
@@ -17,6 +17,8 @@ import { ConnectionWidget } from 'sql/workbench/services/connection/browser/conn
|
||||
import { IServerGroupController } from 'sql/platform/serverGroup/common/serverGroupController';
|
||||
import { ILogService } from 'vs/platform/log/common/log';
|
||||
import { ConnectionProviderProperties } from 'sql/platform/capabilities/common/capabilitiesService';
|
||||
import { assign } from 'vs/base/common/objects';
|
||||
import { find } from 'vs/base/common/arrays';
|
||||
|
||||
export class ConnectionController implements IConnectionComponentController {
|
||||
private _advancedController: AdvancedPropertiesController;
|
||||
@@ -139,7 +141,7 @@ export class ConnectionController implements IConnectionComponentController {
|
||||
} else {
|
||||
defaultGroupId = Utils.defaultGroupId;
|
||||
}
|
||||
allGroups.push(Object.assign({}, this._connectionWidget.DefaultServerGroup, { id: defaultGroupId }));
|
||||
allGroups.push(assign({}, this._connectionWidget.DefaultServerGroup, { id: defaultGroupId }));
|
||||
allGroups.push(this._connectionWidget.NoneServerGroup);
|
||||
connectionGroupRoot.forEach(cpg => cpg.dispose());
|
||||
return allGroups;
|
||||
@@ -149,7 +151,7 @@ export class ConnectionController implements IConnectionComponentController {
|
||||
this._connectionWidget.updateServerGroup(this.getAllServerGroups(providers));
|
||||
this._model = connectionInfo;
|
||||
this._model.providerName = this._providerName;
|
||||
let appNameOption = this._providerOptions.find(option => option.specialValueType === ConnectionOptionSpecialType.appName);
|
||||
let appNameOption = find(this._providerOptions, option => option.specialValueType === ConnectionOptionSpecialType.appName);
|
||||
if (appNameOption) {
|
||||
let appNameKey = appNameOption.name;
|
||||
this._model.options[appNameKey] = Constants.applicationName;
|
||||
|
||||
Reference in New Issue
Block a user