Skip to content

Commit

Permalink
some review edits done
Browse files Browse the repository at this point in the history
  • Loading branch information
mattlockyer committed Oct 10, 2020
1 parent 9fc947f commit 7efb781
Showing 1 changed file with 2 additions and 10 deletions.
12 changes: 2 additions & 10 deletions src/account_multisig.ts
Original file line number Diff line number Diff line change
Expand Up @@ -216,16 +216,8 @@ export class AccountMultisig extends Account {
return requestId
}

async getCodeDefault(): Promise<string> {
if (typeof window === 'undefined') {
throw new Error('There is no getCodeFallback for Node env. Please provide your own in AccountMultisig constructor options argument.');
}
const method = await this.get2faMethod();
if (!method || !method.kind) {
throw new Error('no active 2fa method found');
}
const code = window.prompt(`Enter security code sent to ${ method.kind.split('2fa-')[1] }`)
return code
async getCodeDefault(method: any): Promise<string> {
throw new Error('There is no getCode callback provided. Please provide your own in AccountMultisig constructor options. It has a parameter method where method.kind is "email" or "phone".');
}

async promptAndVerify() {
Expand Down

0 comments on commit 7efb781

Please sign in to comment.