Stricter tslint rules (#9352)

This commit is contained in:
Amir Omidi
2020-03-06 13:06:44 -08:00
committed by GitHub
parent f3a255a7f7
commit 20f7670b32
16 changed files with 44 additions and 32 deletions

View File

@@ -3,6 +3,8 @@
* Licensed under the Source EULA. See License.txt in the project root for license information.
*--------------------------------------------------------------------------------------------*/
/* eslint-disable @typescript-eslint/no-floating-promises */
import { IMainContext } from 'vs/workbench/api/common/extHost.protocol';
import { Emitter } from 'vs/base/common/event';
import { deepClone, assign } from 'vs/base/common/objects';

View File

@@ -4,6 +4,7 @@
*--------------------------------------------------------------------------------------------*/
import { localize } from 'vs/nls';
import * as errors from 'vs/base/common/errors';
import * as vscode from 'vscode';
import { SqlMainContext, ExtHostModelViewTreeViewsShape, MainThreadModelViewShape } from 'sql/workbench/api/common/sqlExtHost.protocol';
import { ITreeComponentItem } from 'sql/workbench/common/views';
@@ -132,7 +133,7 @@ export class ExtHostTreeView<T> extends vsTreeExt.ExtHostTreeView<T> {
} else {
const handlesToRefresh = this.getHandlesToRefresh(elements);
if (handlesToRefresh.length) {
this.refreshHandles(handlesToRefresh);
this.refreshHandles(handlesToRefresh).catch(errors.onUnexpectedError);
}
}
}

View File

@@ -83,7 +83,7 @@ export class ExtHostObjectExplorerNode implements azdata.objectexplorer.ObjectEx
let parentPathEndIndex: number = this.nodePath.lastIndexOf(nodePathName) - 1;
if (parentPathEndIndex < 0) {
// At root node
Promise.resolve(undefined);
return Promise.resolve(undefined);
}
return this._proxy.$getNode(this.connectionId, this.nodePath.slice(0, parentPathEndIndex)).then(
nodeInfo => nodeInfo ? new ExtHostObjectExplorerNode(nodeInfo, this.connectionId, this._proxy) : undefined);