contract shard to config

pull/241/head
jenya 2 years ago
parent 81a7286fef
commit 95fe09992a
  1. 1
      .env
  2. 1
      .env.devnet
  3. 1
      .env.example
  4. 3
      .env.testnet
  5. 2
      src/api/client.ts

@ -6,3 +6,4 @@ REACT_APP_AVAILABLE_SHARDS=0,1,2,3
REACT_APP_EXPLORER_V1_API_URL=https://ctrver.t.hmny.io/
REACT_APP_INDEXER_IPFS_GATEWAY=https://ipfs.io/ipfs/
REACT_APP_PROD_ADDRESS=https://ws.explorer-v2-api.hmny.io
REACT_APP_CONTRACT_SHARD=0

@ -6,3 +6,4 @@ REACT_APP_AVAILABLE_SHARDS=0,1
REACT_APP_EXPLORER_V1_API_URL=https://ctrver.t.hmny.io/
REACT_APP_INDEXER_IPFS_GATEWAY=https://ipfs.io/ipfs/
REACT_APP_PROD_ADDRESS=https://explorer-v2-api.ps.hmny.io
REACT_APP_CONTRACT_SHARD=0

@ -11,3 +11,4 @@ REACT_APP_EXPLORER_V1_API_URL=https://ctrver.t.hmny.io/
REACT_APP_INDEXER_IPFS_GATEWAY=https://ipfs.io/ipfs/
# backend websocket API url
REACT_APP_PROD_ADDRESS=https://explorer-v2-api.hmny.io/
REACT_APP_CONTRACT_SHARD=0

@ -5,4 +5,5 @@ REACT_APP_RPC_URL_SHARD3=https://api.s3.b.hmny.io/
REACT_APP_AVAILABLE_SHARDS=0,1,2,3
REACT_APP_EXPLORER_V1_API_URL=https://ctrver.t.hmny.io/
REACT_APP_INDEXER_IPFS_GATEWAY=https://ipfs.io/ipfs/
REACT_APP_PROD_ADDRESS=https://api.explorer.pops.one/
REACT_APP_PROD_ADDRESS=https://api.explorer.pops.one/
REACT_APP_CONTRACT_SHARD=0

@ -25,7 +25,7 @@ import { eth_traceTransaction } from './rpc'
// TODO: hardcode
let pairCache: { [pair: string]: IPairPrice } = {};
const contractShardID = 1
const contractShardID = +process.env.REACT_APP_CONTRACT_SHARD || 0
setInterval(() => {
pairCache = {};

Loading…
Cancel
Save