Skip to content

Commit 98f8071

Browse files
committed
Merge pull request #236 from DimitarChristoff/bug-235-enumerables
fixing looping array via for in to normal loop
2 parents 7f9d623 + e4593af commit 98f8071

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

Diff for: lib/socket.js

+1-1
Original file line numberDiff line numberDiff line change
@@ -259,7 +259,7 @@ Socket.prototype.setupSendCallback = function () {
259259
seqFn(self.transport);
260260
} else if (Array.isArray(seqFn)) {
261261
debug('executing batch send callback');
262-
for (var i in seqFn) {
262+
for (var l = seqFn.length, i = 0; i < l; i++) {
263263
if ('function' == typeof seqFn[i]) {
264264
seqFn[i](self.transport);
265265
}

0 commit comments

Comments
 (0)