File tree Expand file tree Collapse file tree 1 file changed +3
-3
lines changed
src/vs/workbench/services/editor/common Expand file tree Collapse file tree 1 file changed +3
-3
lines changed Original file line number Diff line number Diff line change @@ -40,7 +40,7 @@ export class CustomEditorLabelService extends Disposable implements ICustomEdito
40
40
private patterns : ICustomEditorLabelPattern [ ] = [ ] ;
41
41
private enabled = true ;
42
42
43
- private cache = new MRUCache < string , string | undefined > ( 1000 ) ;
43
+ private cache = new MRUCache < string , string | null > ( 1000 ) ;
44
44
45
45
constructor (
46
46
@IConfigurationService private readonly configurationService : IConfigurationService ,
@@ -123,11 +123,11 @@ export class CustomEditorLabelService extends Disposable implements ICustomEdito
123
123
const key = resource . toString ( ) ;
124
124
const cached = this . cache . get ( key ) ;
125
125
if ( cached !== undefined ) {
126
- return cached ;
126
+ return cached ?? undefined ;
127
127
}
128
128
129
129
const result = this . applyPatterns ( resource ) ;
130
- this . cache . set ( key , result ) ;
130
+ this . cache . set ( key , result ?? null ) ;
131
131
132
132
return result ;
133
133
}
You can’t perform that action at this time.
0 commit comments