diff --git a/src/cid.ts b/src/cid.ts index 9e0dcdf..2f9b31c 100644 --- a/src/cid.ts +++ b/src/cid.ts @@ -42,6 +42,10 @@ export default class CID extends Multibase { return CID._init(bytes); } + static fromRegistryPublicKey(pubkey: string | Uint8Array): CID { + return CID.fromHash(pubkey, 0, CID_TYPES.RESOLVER); + } + static fromHash( bytes: string | Uint8Array, size: number,