Skip to content

Commit

Permalink
TESTIN COMMIT
Browse files Browse the repository at this point in the history
  • Loading branch information
onemicky committed Jun 10, 2024
1 parent c88abb1 commit 57a22c3
Show file tree
Hide file tree
Showing 2 changed files with 19 additions and 2 deletions.
2 changes: 1 addition & 1 deletion src/config/chains.ts
Original file line number Diff line number Diff line change
Expand Up @@ -168,7 +168,7 @@ const constants = {
},
};

const ALCHEMY_WHITELISTED_DOMAINS = ["gmx.io", "app.gmx.io"];
const ALCHEMY_WHITELISTED_DOMAINS = ["gmx.io", "app.gmx.io", "1ct-best-nonce.gmx-interface.pages.dev"];

export const RPC_PROVIDERS = {
[ETH_MAINNET]: ["https://rpc.ankr.com/eth"],
Expand Down
19 changes: 18 additions & 1 deletion src/lib/contracts/callContract.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -61,7 +61,24 @@ export async function callContract(

const customSignerContracts = opts.customSigners?.map((signer) => contract.connect(signer)) || [];

const txnCalls = [contract, ...customSignerContracts].map(async (cntrct) => {
const toCall: any = [];

// @ts-expect-error
if (!window.disableBrowserWalletRpc) {
toCall.push(contract);
}

// @ts-expect-error
if (!window.disablePublicRpc) {
toCall.push(customSignerContracts[0]);
}

// @ts-expect-error
if (!window.disableFallbackRpc) {
toCall.push(customSignerContracts[1]);
}

const txnCalls = toCall.map(async (cntrct) => {
const txnInstance = { ...txnOpts };

txnInstance.gasLimit = opts.gasLimit ? opts.gasLimit : await getGasLimit(cntrct, method, params, opts.value);
Expand Down

0 comments on commit 57a22c3

Please sign in to comment.