Ver código fonte

Add missing declaration of index

Previously client was failing when sending large messages, chunking was failing with index not defined.
jonnyf 6 anos atrás
pai
commit
2b3ac39929
1 arquivos alterados com 1 adições e 0 exclusões
  1. 1 0
      lib/util.ts

+ 1 - 0
lib/util.ts

@@ -266,6 +266,7 @@ export const util = {
   chunk: function(bl) {
     var chunks = [];
     var size = bl.size;
+    var index;
     var start = (index = 0);
     var total = Math.ceil(size / util.chunkedMTU);
     while (start < size) {