Get tests passing again
This commit is contained in:
@ -1,10 +1,10 @@
|
||||
export default function bufferStream(stream) {
|
||||
return new Promise((resolve, reject) => {
|
||||
return new Promise((accept, reject) => {
|
||||
const chunks = [];
|
||||
|
||||
stream
|
||||
.on('error', reject)
|
||||
.on('data', chunk => chunks.push(chunk))
|
||||
.on('end', () => resolve(Buffer.concat(chunks)));
|
||||
.on('end', () => accept(Buffer.concat(chunks)));
|
||||
});
|
||||
}
|
||||
|
Reference in New Issue
Block a user