diff options
| author | Laurențiu Nicola <lnicola@dend.ro> | 2022-04-20 07:34:00 +0300 |
|---|---|---|
| committer | Laurențiu Nicola <lnicola@dend.ro> | 2022-04-20 07:34:00 +0300 |
| commit | ad751e08ec653eb856c598ab2b9402b3051eeda4 (patch) | |
| tree | 9ff2f75f1b4046530b9565f9f0d01469b3218fa2 | |
| parent | 4de7793425c6932caafe76070e0988d6afca0bc2 (diff) | |
| download | rust-ad751e08ec653eb856c598ab2b9402b3051eeda4.tar.gz rust-ad751e08ec653eb856c598ab2b9402b3051eeda4.zip | |
Pass the language id when toggling inlay hints
| -rw-r--r-- | editors/code/src/commands.ts | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/editors/code/src/commands.ts b/editors/code/src/commands.ts index a808d5ec6d8..1e89938c052 100644 --- a/editors/code/src/commands.ts +++ b/editors/code/src/commands.ts @@ -300,10 +300,9 @@ export function serverVersion(ctx: Ctx): Cmd { export function toggleInlayHints(_ctx: Ctx): Cmd { return async () => { - const scope = vscode.ConfigurationTarget.Global; - const config = vscode.workspace.getConfiguration("editor.inlayHints"); + const config = vscode.workspace.getConfiguration("editor.inlayHints", { languageId: "rust" }); const value = !config.get("enabled"); - await config.update('enabled', value, scope); + await config.update('enabled', value, vscode.ConfigurationTarget.Global); }; } |
