Skip to content

Commit

Permalink
fix: no sense setting DID if address hasn't been set
Browse files Browse the repository at this point in the history
So checking this._address when setDid()
  • Loading branch information
jrhender committed May 15, 2021
1 parent 9018f07 commit 8b182df
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion src/iam/iam-base.ts
Expand Up @@ -376,7 +376,9 @@ export class IAMBase {
}

private setDid() {
this._did = `did:${Methods.Erc1056}:${this._address}`;
if (this._address) {
this._did = `did:${Methods.Erc1056}:${this._address}`;
}
}

private async setDocument() {
Expand Down

0 comments on commit 8b182df

Please sign in to comment.