git ssb

1+

Dominic / pull-stream-workshop



Tree: 079013977dd1a81caf9ed4717492ef3b9f722db0

Files: 079013977dd1a81caf9ed4717492ef3b9f722db0 / solutions / 02.js

202 bytesRaw
1
2
3module.exports = function (array) {
4 var i = 0
5 return function (abort, cb) {
6 if(abort)
7 cb(abort)
8 else if(i >= array.length)
9 cb(true)
10 else
11 cb(null, array[i++])
12 }
13
14}
15
16

Built with git-ssb-web