Skip to content

Commit

Permalink
enhance: update infura key
Browse files Browse the repository at this point in the history
  • Loading branch information
mordochi committed Dec 5, 2023
1 parent 6f8b5c4 commit 125e8fc
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 3 deletions.
3 changes: 2 additions & 1 deletion .env.example
Original file line number Diff line number Diff line change
@@ -1,2 +1,3 @@
REACT_APP_DAPP_ID=
REACT_APP_NETWORK=testnet
REACT_APP_NETWORK=testnet
REACT_APP_INFURA_KEY=
6 changes: 4 additions & 2 deletions src/services/evm.ts
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,9 @@ export const supportedChains = [
{
name: "Ethereum Mainnet",
chainId: "0x1",
rpcUrls: ["https://mainnet.infura.io/v3/ef5a5728e2354955b562d2ffa4ae5305"],
rpcUrls: [
`https://mainnet.infura.io/v3/${process.env.REACT_APP_INFURA_KEY}`,
],
environment: "mainnet",
},
{
Expand Down Expand Up @@ -100,7 +102,7 @@ const bloctoSDK = new BloctoSDK({
chainId: isMainnet ? "0x1" : "0x5",
// (required for Ethereum) JSON RPC endpoint
rpc: isMainnet
? "https://mainnet.infura.io/v3/ef5a5728e2354955b562d2ffa4ae5305"
? `https://mainnet.infura.io/v3/${process.env.REACT_APP_INFURA_KEY}`
: "https://rpc.ankr.com/eth_goerli",
},
appId: process.env.REACT_APP_DAPP_ID,
Expand Down

0 comments on commit 125e8fc

Please sign in to comment.