From df7ee603cb897a2edec4e45868321f00a200a020 Mon Sep 17 00:00:00 2001 From: Johannes Rieken Date: Thu, 29 Mar 2018 15:28:15 +0200 Subject: [PATCH] follow up on #46880 --- .../src/features/quickFixProvider.ts | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/extensions/typescript-language-features/src/features/quickFixProvider.ts b/extensions/typescript-language-features/src/features/quickFixProvider.ts index a85e78e7b6e..088e9734ba8 100644 --- a/extensions/typescript-language-features/src/features/quickFixProvider.ts +++ b/extensions/typescript-language-features/src/features/quickFixProvider.ts @@ -110,7 +110,7 @@ class SupportedCodeActionProvider { public async getFixableDiagnosticsForContext(context: vscode.CodeActionContext): Promise { const supportedActions = await this.supportedCodeActions; - const fixableDiagnostics = DiagnosticsSet.from(context.diagnostics.filter(diagnostic => supportedActions.has(+diagnostic.code))); + const fixableDiagnostics = DiagnosticsSet.from(context.diagnostics.filter(diagnostic => supportedActions.has(+!diagnostic.code))); return Array.from(fixableDiagnostics.values); } @@ -184,7 +184,7 @@ export default class TypeScriptQuickFixProvider implements vscode.CodeActionProv ): Promise> { const args: Proto.CodeFixRequestArgs = { ...typeConverters.Range.toFileRangeRequestArgs(file, diagnostic.range), - errorCodes: [+diagnostic.code] + errorCodes: [+!diagnostic.code] }; const codeFixesResponse = await this.client.execute('getCodeFixes', args, token); if (codeFixesResponse.body) {