mirror of
https://github.com/microsoft/vscode.git
synced 2026-04-24 02:28:34 +01:00
Replace map with forEach (#115378)
The callback provided to the map call on this array should return a value, otherwise map will always return an array of undefined values. If the desired behaviour is to just iterate through all elements, then consider using forEach or a for-of loop instead.
This commit is contained in:
committed by
GitHub
parent
feeeb58be0
commit
67561036cf
@@ -125,7 +125,7 @@ export class GitHubAuthenticationProvider implements vscode.AuthenticationProvid
|
||||
}
|
||||
});
|
||||
|
||||
this._sessions.map(session => {
|
||||
this._sessions.forEach(session => {
|
||||
const matchesExisting = storedSessions.some(s => s.id === session.id);
|
||||
// Another window has logged out, remove from our state
|
||||
if (!matchesExisting) {
|
||||
|
||||
Reference in New Issue
Block a user