File tree Expand file tree Collapse file tree 1 file changed +5
-6
lines changed
src/vs/workbench/api/common Expand file tree Collapse file tree 1 file changed +5
-6
lines changed Original file line number Diff line number Diff line change @@ -945,14 +945,13 @@ class EnvironmentVariableCollection {
945
945
}
946
946
947
947
public getVariableMap ( scope : vscode . EnvironmentVariableScope | undefined ) : Map < string , IEnvironmentVariableMutator > {
948
- const scopedMap = new Map < string , IEnvironmentVariableMutator > ( ) ;
949
- const scopeKey = this . getScopeKey ( scope ) ;
950
- for ( const [ key , value ] of this . map . entries ( ) ) {
951
- if ( key === scopeKey ) {
952
- scopedMap . set ( value . variable , value ) ;
948
+ const map = new Map < string , IEnvironmentVariableMutator > ( ) ;
949
+ for ( const [ key , value ] of this . map ) {
950
+ if ( this . getScopeKey ( value . scope ) === this . getScopeKey ( scope ) ) {
951
+ map . set ( key , value ) ;
953
952
}
954
953
}
955
- return scopedMap ;
954
+ return map ;
956
955
}
957
956
958
957
delete ( variable : string , scope : vscode . EnvironmentVariableScope | undefined ) : void {
You can’t perform that action at this time.
0 commit comments