We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent b442488 commit d172361Copy full SHA for d172361
src/index.js
@@ -20,7 +20,7 @@ const { BlockstoreAdapter } = require('interface-blockstore')
20
function cidToKey (cid) {
21
const c = CID.asCID(cid)
22
23
- if (!(c instanceof CID)) {
+ if (!c) {
24
throw errcode(new Error('Not a valid cid'), 'ERR_INVALID_CID')
25
}
26
0 commit comments