Skip to content

Commit

Permalink
fix: endpoints
Browse files Browse the repository at this point in the history
  • Loading branch information
fadeev committed Dec 21, 2023
1 parent 1096164 commit 8bd9d69
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 5 deletions.
2 changes: 1 addition & 1 deletion helpers/balances.ts
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ import fetch from "isomorphic-fetch";

export const getForeignCoins = async () => {
const api = getEndpoints("cosmos-http", "zeta_testnet")[0]?.url;
const endpoint = `${api}/zeta-chain/zetacore/fungible/foreign_coins`;
const endpoint = `${api}/zeta-chain/fungible/foreign_coins`;
const response = await fetch(endpoint);
const data = await response.json();
return data.foreignCoins;
Expand Down
2 changes: 1 addition & 1 deletion helpers/pools.ts
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ import fetch from "isomorphic-fetch";

export const getPools = async () => {
const api = getEndpoints("cosmos-http", "zeta_testnet")[0]?.url;
const endpoint = `${api}/zeta-chain/zetacore/fungible/foreign_coins`;
const endpoint = `${api}/zeta-chain/fungible/foreign_coins`;
const response = await fetch(endpoint);
const data = await response.json();

Expand Down
4 changes: 1 addition & 3 deletions helpers/sendZRC20.ts
Original file line number Diff line number Diff line change
Expand Up @@ -24,9 +24,7 @@ export const sendZRC20 = async (
}

const API = getEndpoints("cosmos-http", "zeta_testnet")?.[0]?.url;
const response = await fetch(
`${API}/zeta-chain/zetacore/fungible/foreign_coins`
);
const response = await fetch(`${API}/zeta-chain/fungible/foreign_coins`);
const data = await response.json();
const foreignCoins = data.foreignCoins;
const networkChainID = networks[network as keyof typeof networks]?.chain_id;
Expand Down

0 comments on commit 8bd9d69

Please sign in to comment.