multiformats
Advanced tools
Comparing version 1.0.0 to 1.0.1
@@ -43,2 +43,4 @@ import varints from 'varint' | ||
if (!info || !info.encode) throw new Error(`Missing hash implementation for "${key}"`) | ||
// https://github.com/bcoe/c8/issues/135 | ||
/* c8 ignore next */ | ||
return encode(await info.encode(buff), key) | ||
@@ -55,2 +57,4 @@ } | ||
} | ||
// https://github.com/bcoe/c8/issues/135 | ||
/* c8 ignore next */ | ||
return true | ||
@@ -57,0 +61,0 @@ } |
@@ -37,2 +37,4 @@ import CID from 'cids' | ||
const hash = await multiformats.multihash.hash(buff, hashAlg) | ||
// https://github.com/bcoe/c8/issues/135 | ||
/* c8 ignore next */ | ||
return new CID(cidVersion, name, Buffer.from(hash)) | ||
@@ -39,0 +41,0 @@ } |
{ | ||
"name": "multiformats", | ||
"version": "1.0.0", | ||
"version": "1.0.1", | ||
"description": "Interface for multihash, multicodec, multibase and CID.", | ||
@@ -12,3 +12,3 @@ "main": "index.js", | ||
"test": "npm run pre:test && npm run test:node && npm run test:browser", | ||
"coverage": "nyc --reporter=html mocha test/test-*.js && npx st -d coverage -p 8080" | ||
"coverage": "c8 --reporter=html mocha test/test-*.js && npx st -d coverage -p 8080" | ||
}, | ||
@@ -23,6 +23,7 @@ "keywords": [], | ||
"devDependencies": { | ||
"hundreds": "0.0.2", | ||
"mocha": "^7.1.1", | ||
"c8": "^7.2.0", | ||
"hundreds": "0.0.4", | ||
"mocha": "^8.0.1", | ||
"polendina": "^1.0.0", | ||
"standard": "^14.3.3" | ||
"standard": "^14.3.4" | ||
}, | ||
@@ -32,3 +33,3 @@ "dependencies": { | ||
"buffer": "^5.6.0", | ||
"cids": "^0.8.0", | ||
"cids": "^0.8.1", | ||
"class-is": "^1.1.0", | ||
@@ -35,0 +36,0 @@ "varint": "^5.0.0" |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
58450
1513
5
Updatedcids@^0.8.1