Skip to content

Commit aa65e4b

Browse files
Aldo Ambrosionitargos
Aldo Ambrosioni
authored andcommitted
src: replaced var with let
replaced var with let in lib/internal/cluter/master.js PR-URL: #30397 Reviewed-By: James M Snell <[email protected]> Reviewed-By: Colin Ihrig <[email protected]> Reviewed-By: Gireesh Punathil <[email protected]> Reviewed-By: Ruben Bridgewater <[email protected]> Reviewed-By: Trivikram Kamat <[email protected]>
1 parent 06251a4 commit aa65e4b

File tree

1 file changed

+6
-6
lines changed

1 file changed

+6
-6
lines changed

lib/internal/cluster/master.js

+6-6
Original file line numberDiff line numberDiff line change
@@ -29,12 +29,12 @@ cluster.settings = {};
2929
cluster.SCHED_NONE = SCHED_NONE; // Leave it to the operating system.
3030
cluster.SCHED_RR = SCHED_RR; // Master distributes connections.
3131

32-
var ids = 0;
33-
var debugPortOffset = 1;
34-
var initialized = false;
32+
let ids = 0;
33+
let debugPortOffset = 1;
34+
let initialized = false;
3535

3636
// XXX(bnoordhuis) Fold cluster.schedulingPolicy into cluster.settings?
37-
var schedulingPolicy = {
37+
let schedulingPolicy = {
3838
'none': SCHED_NONE,
3939
'rr': SCHED_RR
4040
}[process.env.NODE_CLUSTER_SCHED_POLICY];
@@ -270,7 +270,7 @@ function queryServer(worker, message) {
270270

271271
const key = `${message.address}:${message.port}:${message.addressType}:` +
272272
`${message.fd}:${message.index}`;
273-
var handle = handles.get(key);
273+
let handle = handles.get(key);
274274

275275
if (handle === undefined) {
276276
let address = message.address;
@@ -285,7 +285,7 @@ function queryServer(worker, message) {
285285
address = message.address;
286286
}
287287

288-
var constructor = RoundRobinHandle;
288+
let constructor = RoundRobinHandle;
289289
// UDP is exempt from round-robin connection balancing for what should
290290
// be obvious reasons: it's connectionless. There is nothing to send to
291291
// the workers except raw datagrams and that's pointless.

0 commit comments

Comments
 (0)