mirror of
https://github.com/microsoft/vscode.git
synced 2026-04-27 20:13:32 +01:00
Fixes more node 12 typing errors (#85420)
* Fixes more node 12 typing errors For #82514 * Remove Symbol.toStringTag usage for now * Reverting a few fixes that are not comptible with current node typings * Revert one more use of StringDecoder Must wait until we actually pick up the new typings
This commit is contained in:
@@ -618,7 +618,7 @@ export interface ITextSearchComplete {
|
||||
|
||||
export interface MainThreadWorkspaceShape extends IDisposable {
|
||||
$startFileSearch(includePattern: string | null, includeFolder: UriComponents | null, excludePatternOrDisregardExcludes: string | false | null, maxResults: number | null, token: CancellationToken): Promise<UriComponents[] | null>;
|
||||
$startTextSearch(query: search.IPatternInfo, options: ITextQueryBuilderOptions, requestId: number, token: CancellationToken): Promise<ITextSearchComplete>;
|
||||
$startTextSearch(query: search.IPatternInfo, options: ITextQueryBuilderOptions, requestId: number, token: CancellationToken): Promise<ITextSearchComplete | undefined>;
|
||||
$checkExists(folders: UriComponents[], includes: string[], token: CancellationToken): Promise<boolean>;
|
||||
$saveAll(includeUntitled?: boolean): Promise<boolean>;
|
||||
$updateWorkspaceFolders(extensionName: string, index: number, deleteCount: number, workspaceFoldersToAdd: { uri: UriComponents, name?: string; }[]): Promise<void>;
|
||||
|
||||
@@ -378,7 +378,7 @@ export class ExtHostDebugServiceBase implements IExtHostDebugService, ExtHostDeb
|
||||
public async $substituteVariables(folderUri: UriComponents | undefined, config: IConfig): Promise<IConfig> {
|
||||
if (!this._variableResolver) {
|
||||
const [workspaceFolders, configProvider] = await Promise.all([this._workspaceService.getWorkspaceFolders2(), this._configurationService.getConfigProvider()]);
|
||||
this._variableResolver = this.createVariableResolver(workspaceFolders || [], this._editorsService, configProvider);
|
||||
this._variableResolver = this.createVariableResolver(workspaceFolders || [], this._editorsService, configProvider!);
|
||||
}
|
||||
let ws: IWorkspaceFolder | undefined;
|
||||
const folder = await this.getFolder(folderUri);
|
||||
|
||||
@@ -135,7 +135,7 @@ export class ExtHostQuickOpen implements ExtHostQuickOpenShape {
|
||||
|
||||
// ---- input
|
||||
|
||||
showInput(options?: InputBoxOptions, token: CancellationToken = CancellationToken.None): Promise<string> {
|
||||
showInput(options?: InputBoxOptions, token: CancellationToken = CancellationToken.None): Promise<string | undefined> {
|
||||
|
||||
// global validate fn used in callback below
|
||||
this._validateInput = options ? options.validateInput : undefined;
|
||||
|
||||
@@ -419,7 +419,7 @@ class ExtHostTreeView<T> extends Disposable {
|
||||
// check if an ancestor of extElement is already in the elements to update list
|
||||
let currentNode: TreeNode | undefined = elementNode;
|
||||
while (currentNode && currentNode.parent && !elementsToUpdate.has(currentNode.parent.item.handle)) {
|
||||
const parentElement = this.elements.get(currentNode.parent.item.handle);
|
||||
const parentElement: T | undefined = this.elements.get(currentNode.parent.item.handle);
|
||||
currentNode = parentElement ? this.nodes.get(parentElement) : undefined;
|
||||
}
|
||||
if (currentNode && !currentNode.parent) {
|
||||
|
||||
Reference in New Issue
Block a user