Skip to content

Commit

Permalink
Read multisig owners from contracts (#43)
Browse files Browse the repository at this point in the history
* query multisig owners from contract

* lower case for owner address

* lint

* lint
  • Loading branch information
fewensa authored Feb 8, 2024
1 parent f0a913b commit a10a620
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 7 deletions.
5 changes: 5 additions & 0 deletions packages/relay-oracle/src/client/contract_multisig.ts
Original file line number Diff line number Diff line change
Expand Up @@ -56,4 +56,9 @@ export class MultisigContractClient {
return await tx.wait();
}

public async getOwners(): Promise<string[]> {
const owners = await this.contract['getOwners']();
return owners.map((item: any) => item.toString().toLowerCase());
}

}
8 changes: 1 addition & 7 deletions packages/relay-oracle/src/relay.ts
Original file line number Diff line number Diff line change
Expand Up @@ -402,13 +402,7 @@ export class OracleRelay extends CommonRelay<OracleRelayLifecycle> {

private async _lastSignature(chainId: number, msgIndex: number): Promise<LastSignature> {
// const owners = await this.targetSafeContract.owners();
const owners = [
"0xfa5727be643dba6599fc7f812fe60da3264a8205",
"0xb9a0cadd13c5d534b034d878b2fca9e5a6e1e3a4",
"0x9f33a4809aa708d7a399fedba514e0a0d15efa85",
"0x178e699c9a6bb2cd624557fbd85ed219e6faba77",
"0xa4be619e8c0e3889f5fa28bb0393a4862cad35ad"
];
const owners = await this.targetMultisigContract.getOwners();
const topSignatures = await this.indexerSigncribe.topSignatures({
chainId,
msgIndex: msgIndex,
Expand Down

0 comments on commit a10a620

Please sign in to comment.