@@ -138,25 +138,24 @@ export class MergedEnvironmentVariableCollection implements IMergedEnvironmentVa
138138
139139 getVariableMap ( scope : EnvironmentVariableScope | undefined ) : Map < string , IExtensionOwnedEnvironmentVariableMutator [ ] > {
140140 const result = new Map < string , IExtensionOwnedEnvironmentVariableMutator [ ] > ( ) ;
141- this . map . forEach ( ( mutators , _key ) => {
141+ for ( const mutators of this . map . values ( ) ) {
142142 const filteredMutators = mutators . filter ( m => filterScope ( m , scope ) ) ;
143143 if ( filteredMutators . length > 0 ) {
144144 // All of these mutators are for the same variable because they are in the same scope, hence choose anyone to form a key.
145145 result . set ( filteredMutators [ 0 ] . variable , filteredMutators ) ;
146146 }
147- } ) ;
147+ }
148148 return result ;
149149 }
150150
151151 getDescriptionMap ( scope : EnvironmentVariableScope | undefined ) : Map < string , string | undefined > {
152152 const result = new Map < string , string | undefined > ( ) ;
153- this . descriptionMap . forEach ( ( mutators , _key ) => {
153+ for ( const mutators of this . descriptionMap . values ( ) ) {
154154 const filteredMutators = mutators . filter ( m => filterScope ( m , scope , true ) ) ;
155- if ( filteredMutators . length > 0 ) {
156- // There should be exactly one description per extension per scope.
157- result . set ( filteredMutators [ 0 ] . extensionIdentifier , filteredMutators [ 0 ] . description ) ;
155+ for ( const mutator of filteredMutators ) {
156+ result . set ( mutator . extensionIdentifier , mutator . description ) ;
158157 }
159- } ) ;
158+ }
160159 return result ;
161160 }
162161
0 commit comments