We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent a0b1aa1 commit c0a2e02Copy full SHA for c0a2e02
lib/net.js
@@ -1502,9 +1502,9 @@ Server.prototype.getConnections = function(cb) {
1502
if (--left === 0) return end(null, total);
1503
}
1504
1505
- this._slaves.forEach(function(slave) {
1506
- slave.getConnections(oncount);
1507
- });
+ for (var n = 0; n < this._slaves.length; n++) {
+ this._slaves[n].getConnections(oncount);
+ }
1508
};
1509
1510
@@ -1540,9 +1540,8 @@ Server.prototype.close = function(cb) {
1540
this._connections++;
1541
1542
// Poll slaves
1543
1544
- slave.close(onSlaveClose);
1545
+ for (var n = 0; n < this._slaves.length; n++)
+ this._slaves[n].close(onSlaveClose);
1546
} else {
1547
this._emitCloseIfDrained();
1548
0 commit comments