Skip to content

Commit 6690072

Browse files
jdneofbricon
authored andcommitted
Enable the 'invert local variable' fix
Signed-off-by: Sheng Chen <sheche@microsoft.com>
1 parent 0020031 commit 6690072

1 file changed

Lines changed: 4 additions & 3 deletions

File tree

src/refactorAction.ts

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@ function registerApplyRefactorCommand(languageClient: LanguageClient, context: E
1414
try {
1515
const uri: Uri = Uri.parse(position.uri);
1616
const document: TextDocument = await workspace.openTextDocument(uri);
17-
if (document == null) {
17+
if (document === null) {
1818
return;
1919
}
2020

@@ -34,7 +34,8 @@ function registerApplyRefactorCommand(languageClient: LanguageClient, context: E
3434
|| command === 'extractConstant'
3535
|| command === 'extractMethod'
3636
|| command === 'extractField'
37-
|| command === 'convertVariableToField') {
37+
|| command === 'convertVariableToField'
38+
|| command === 'invertVariable') {
3839
const currentEditor = window.activeTextEditor;
3940
if (!currentEditor || !currentEditor.options) {
4041
return;
@@ -80,7 +81,7 @@ function registerApplyRefactorCommand(languageClient: LanguageClient, context: E
8081
if (edit) {
8182
await workspace.applyEdit(edit);
8283
}
83-
84+
8485
if (result.command) {
8586
if (result.command.arguments) {
8687
await commands.executeCommand(result.command.command, ...result.command.arguments);

0 commit comments

Comments
 (0)