mirror of
https://github.com/S2-/gitlit
synced 2025-08-04 05:10:05 +02:00
update dependencies
This commit is contained in:
11
node_modules/concat-stream/index.js
generated
vendored
11
node_modules/concat-stream/index.js
generated
vendored
@@ -1,5 +1,6 @@
|
||||
var Writable = require('readable-stream').Writable
|
||||
var inherits = require('inherits')
|
||||
var bufferFrom = require('buffer-from')
|
||||
|
||||
if (typeof Uint8Array === 'undefined') {
|
||||
var U8 = require('typedarray').Uint8Array
|
||||
@@ -87,9 +88,9 @@ function stringConcat (parts) {
|
||||
} else if (Buffer.isBuffer(p)) {
|
||||
strings.push(p)
|
||||
} else if (isBufferish(p)) {
|
||||
strings.push(new Buffer(p))
|
||||
strings.push(bufferFrom(p))
|
||||
} else {
|
||||
strings.push(new Buffer(String(p)))
|
||||
strings.push(bufferFrom(String(p)))
|
||||
}
|
||||
}
|
||||
if (Buffer.isBuffer(parts[0])) {
|
||||
@@ -108,9 +109,9 @@ function bufferConcat (parts) {
|
||||
if (Buffer.isBuffer(p)) {
|
||||
bufs.push(p)
|
||||
} else if (isBufferish(p)) {
|
||||
bufs.push(new Buffer(p))
|
||||
bufs.push(bufferFrom(p))
|
||||
} else {
|
||||
bufs.push(new Buffer(String(p)))
|
||||
bufs.push(bufferFrom(String(p)))
|
||||
}
|
||||
}
|
||||
return Buffer.concat(bufs)
|
||||
@@ -128,7 +129,7 @@ function u8Concat (parts) {
|
||||
var len = 0
|
||||
for (var i = 0; i < parts.length; i++) {
|
||||
if (typeof parts[i] === 'string') {
|
||||
parts[i] = new Buffer(parts[i])
|
||||
parts[i] = bufferFrom(parts[i])
|
||||
}
|
||||
len += parts[i].length
|
||||
}
|
||||
|
Reference in New Issue
Block a user