Update implementation to new simple-sink API

master
Sven Slootweg 4 years ago
parent 402cfcb457
commit 3ccc2d5ed9

@ -5,9 +5,12 @@ const simpleSink = require("@ppstreams/simple-sink");
module.exports = function collect() { module.exports = function collect() {
let results = []; let results = [];
return simpleSink((value) => { return simpleSink({
results.push(value); onResult: (value) => {
results.push(value);
return results; },
onEnd: () => {
return results;
}
}); });
}; };

Loading…
Cancel
Save