Skip to content

Commit

Permalink
feat: Add method for fetching multisig request
Browse files Browse the repository at this point in the history
  • Loading branch information
morgsmccauley committed Mar 17, 2022
1 parent 1ba1a77 commit 9a4d904
Showing 1 changed file with 14 additions and 0 deletions.
14 changes: 14 additions & 0 deletions packages/frontend/src/utils/twoFactor.js
Original file line number Diff line number Diff line change
Expand Up @@ -48,6 +48,20 @@ export class TwoFactor extends Account2FA {
});
}

async getMultisigRequest() {
const request = this.getRequest();
const { receiver_id } = await this.viewFunction(
this.accountId,
'get_request',
{ request_id: request.requestId }
);

return {
...request,
receiverId: receiver_id,
};
}

async deployMultisig() {
const contractBytes = new Uint8Array(await (await fetch('/multisig.wasm')).arrayBuffer());
await super.deployMultisig(contractBytes);
Expand Down

0 comments on commit 9a4d904

Please sign in to comment.