We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 5e38565 commit f4c80d7Copy full SHA for f4c80d7
lib/parser.js
@@ -319,14 +319,14 @@ function concatBulkString (parser) {
319
if (chunks === 2) {
320
return list[0].toString('utf8', parser.bigOffset, list[0].length - 1)
321
}
322
- } else {
323
- chunks++
+ chunks--
+ offset = list[list.length - 2].length + 1
324
325
var res = decoder.write(list[0].slice(parser.bigOffset))
326
- for (var i = 1; i < chunks - 2; i++) {
+ for (var i = 1; i < chunks - 1; i++) {
327
res += decoder.write(list[i])
328
329
- res += decoder.end(list[i].slice(0, offset === 1 ? list[i].length - 1 : offset - 2))
+ res += decoder.end(list[i].slice(0, offset - 2))
330
return res
331
332
0 commit comments