Closed nichoth closed 4 years ago
Sorry, I don't think I understand. What's the problem you're facing, or maybe what do you expect to happen instead?
yes, so there should be two possible outputs, either err is equal to something, or err
is null and hash is valid. this is something else -- no error but hash
is not a valid hash. I ended up getting around this by taking the hash in the client as a separate function call. I think this is about making the behavior the same as the documentation.
Hmm, that's very strange. I just tested locally and it looks like it's giving me what I expect, but I'm using blobs.add(hash, cb)
. :thinking:
ok, so it looks like you are also getting the hash as a separate step, and the blobs.add
call returns what was passed in. Looking at the docs https://scuttlebot.io/apis/scuttlebot/blobs.html this is what it says should happen. I'm not sure why I was confused when I opened this, thanks for looking.
Trying to add an 'avatar' type image in sbot. https://github.com/nichoth/eventual/blob/master/src/subscribe.js#L41