Skip to content

Commit

Permalink
test: replace forEach() with for ... of in test-tls-getprotocol.js
Browse files Browse the repository at this point in the history
PR-URL: #50600
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
Reviewed-By: Marco Ippolito <marcoippolito54@gmail.com>
  • Loading branch information
SociableSteve authored and RafaelGSS committed Nov 29, 2023
1 parent 9197b0f commit 3b79983
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions test/parallel/test-tls-getprotocol.js
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@ const serverConfig = {
const server = tls.createServer(serverConfig, common.mustCall(clientConfigs.length))
.listen(0, common.localhostIPv4, function() {
let connected = 0;
clientConfigs.forEach(function(v) {
for (const v of clientConfigs) {
tls.connect({
host: common.localhostIPv4,
port: server.address().port,
Expand All @@ -51,5 +51,5 @@ const server = tls.createServer(serverConfig, common.mustCall(clientConfigs.leng
if (++connected === clientConfigs.length)
server.close();
}));
});
}
});

0 comments on commit 3b79983

Please sign in to comment.