@@ -27,14 +27,19 @@ export class HintsUpdater {
27
27
if ( this . displayHints ) {
28
28
const documentUri = this . getEditorDocumentUri ( editor ) ;
29
29
if ( documentUri !== null ) {
30
- const latestDecorations = this . drawnDecorations . get ( documentUri ) ;
30
+ const latestDecorations = this . drawnDecorations . get (
31
+ documentUri
32
+ ) ;
31
33
if ( latestDecorations === undefined ) {
32
34
await this . updateDecorationsFromServer (
33
35
documentUri ,
34
36
editor !
35
37
) ;
36
38
} else {
37
- await editor ! . setDecorations ( typeHintDecorationType , latestDecorations ) ;
39
+ await editor ! . setDecorations (
40
+ typeHintDecorationType ,
41
+ latestDecorations
42
+ ) ;
38
43
}
39
44
}
40
45
}
@@ -48,9 +53,12 @@ export class HintsUpdater {
48
53
if ( displayHints ) {
49
54
return this . updateHints ( ) ;
50
55
} else {
51
- const editor = vscode . window . activeTextEditor ;
52
- if ( this . getEditorDocumentUri ( editor ) !== null ) {
53
- return editor ! . setDecorations ( typeHintDecorationType , [ ] ) ;
56
+ const currentEditor = vscode . window . activeTextEditor ;
57
+ if ( this . getEditorDocumentUri ( currentEditor ) !== null ) {
58
+ return currentEditor ! . setDecorations (
59
+ typeHintDecorationType ,
60
+ [ ]
61
+ ) ;
54
62
}
55
63
}
56
64
}
@@ -92,7 +100,10 @@ export class HintsUpdater {
92
100
93
101
this . drawnDecorations . set ( documentUri , newDecorations ) ;
94
102
95
- if ( this . getEditorDocumentUri ( vscode . window . activeTextEditor ) === documentUri ) {
103
+ if (
104
+ this . getEditorDocumentUri ( vscode . window . activeTextEditor ) ===
105
+ documentUri
106
+ ) {
96
107
return editor . setDecorations (
97
108
typeHintDecorationType ,
98
109
newDecorations
0 commit comments