Skip to content

Commit

Permalink
Fix method mixup typos in comments
Browse files Browse the repository at this point in the history
Signed-off-by: Frank Hinek <[email protected]>
  • Loading branch information
frankhinek committed Feb 9, 2024
1 parent b63fe25 commit 51e3a8f
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 4 deletions.
3 changes: 2 additions & 1 deletion packages/dids/src/methods/did-ion.ts
Original file line number Diff line number Diff line change
Expand Up @@ -298,7 +298,8 @@ const DEFAULT_GATEWAY_URI = 'https://ion.tbd.engineering';
* - DID Key Management: Instantiate a DID object from an existing key in a Key Management System
* (KMS). If supported by the KMS, a DID's key can be exported to a portable
* DID format.
* - DID Resolution: Resolve a `did:ion` to its corresponding DID Document stored in the DHT network.
* - DID Resolution: Resolve a `did:ion` to its corresponding DID Document stored in the Sidetree
* network.
* - Signature Operations: Sign and verify messages using keys associated with a DID.
*
* @see {@link https://identity.foundation/sidetree/spec/ | Sidetree Protocol Specification}
Expand Down
6 changes: 3 additions & 3 deletions packages/dids/src/methods/did-key.ts
Original file line number Diff line number Diff line change
Expand Up @@ -67,7 +67,7 @@ import { getVerificationMethodTypes, keyBytesToMultibaseId, multibaseIdToKeyByte
*
* // DID Creation with a KMS
* const keyManager = new LocalKeyManager();
* const did = await DidJwk.create({ keyManager });
* const did = await DidKey.create({ keyManager });
*
* // DID Resolution
* const resolutionResult = await DidKey.resolve({ did: did.uri });
Expand All @@ -83,7 +83,7 @@ import { getVerificationMethodTypes, keyBytesToMultibaseId, multibaseIdToKeyByte
* const portableDid = await did.export();
*
* // Reconstruct a BearerDid object from a PortableDid
* const did = await DidJwk.import(portableDid);
* const did = await DidKey.import(portableDid);
* ```
*/
export interface DidKeyCreateOptions<TKms> extends DidCreateOptions<TKms> {
Expand Down Expand Up @@ -351,7 +351,7 @@ export class DidKey extends DidMethod {
throw new Error(`The 'algorithm' and 'verificationMethods' options are mutually exclusive`);
}

// Check 2: If `verificationMethods` is given, it must contain exactly one entry since DID JWK
// Check 2: If `verificationMethods` is given, it must contain exactly one entry since DID Key
// only supports a single verification method.
if (options.verificationMethods && options.verificationMethods.length !== 1) {
throw new Error(`The 'verificationMethods' option must contain exactly one entry`);
Expand Down

0 comments on commit 51e3a8f

Please sign in to comment.