@dfinity/principal
Advanced tools
Comparing version 0.10.3 to 0.10.4
@@ -20,3 +20,3 @@ "use strict"; | ||
static selfAuthenticating(publicKey) { | ||
const sha = sha224_1.sha224(publicKey); | ||
const sha = (0, sha224_1.sha224)(publicKey); | ||
return new this(new Uint8Array([...sha, SELF_AUTHENTICATING_SUFFIX])); | ||
@@ -40,3 +40,3 @@ } | ||
const canisterIdNoDash = text.toLowerCase().replace(/-/g, ''); | ||
let arr = base32_1.decode(canisterIdNoDash); | ||
let arr = (0, base32_1.decode)(canisterIdNoDash); | ||
arr = arr.slice(4, arr.length); | ||
@@ -64,7 +64,7 @@ const principal = new this(arr); | ||
const view = new DataView(checksumArrayBuf); | ||
view.setUint32(0, getCrc_1.getCrc32(this._arr)); | ||
view.setUint32(0, (0, getCrc_1.getCrc32)(this._arr)); | ||
const checksum = new Uint8Array(checksumArrayBuf); | ||
const bytes = Uint8Array.from(this._arr); | ||
const array = new Uint8Array([...checksum, ...bytes]); | ||
const result = base32_1.encode(array); | ||
const result = (0, base32_1.encode)(array); | ||
const matches = result.match(/.{1,5}/g); | ||
@@ -71,0 +71,0 @@ if (!matches) { |
{ | ||
"name": "@dfinity/principal", | ||
"version": "0.10.3", | ||
"version": "0.10.4", | ||
"author": "DFINITY Stiftung <sdk@dfinity.org>", | ||
@@ -5,0 +5,0 @@ "license": "Apache-2.0", |
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
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
New author
Supply chain riskA new npm collaborator published a version of the package for the first time. New collaborators are usually benign additions to a project, but do indicate a change to the security surface area of a package.
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
92858
1