Add feature to want() missing blobs

This commit is contained in:
Christian Bundy
2019-09-23 08:45:18 -07:00
parent 2c7b4ac130
commit b18fdab014
3 changed files with 9 additions and 2 deletions

View File

@ -8,5 +8,10 @@ module.exports = {
debug('requested blob: %s', blobId)
const ssb = await cooler.connect()
return cooler.read(ssb.blobs.get, blobId)
},
want: async ({ blobId }) => {
debug('requested blob: %s', blobId)
const ssb = await cooler.connect()
return cooler.get(ssb.blobs.want, blobId)
}
}