Skip to content

Commit

Permalink
chore: remove api key replacement for evm (#900)
Browse files Browse the repository at this point in the history
  • Loading branch information
0xKheops authored Jul 3, 2023
1 parent 693e89b commit 02f64b2
Show file tree
Hide file tree
Showing 2 changed files with 1 addition and 17 deletions.
3 changes: 1 addition & 2 deletions apps/extension/src/ui/domains/Ethereum/Networks/helpers.ts
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
import { EvmNetworkId } from "@talismn/chaindata-provider"
import { getRpcUrlWithApiKey } from "@ui/util/getRpcUrlWithApiKey"
import { ethers } from "ethers"

// because of validation the same query is done 3 times minimum per url, make all await same promise
Expand All @@ -13,7 +12,7 @@ export const getRpcChainId = (rpcUrl: string) => {
rpcChainIdCache.set(
rpcUrl,
new Promise((resolve) => {
const provider = new ethers.providers.StaticJsonRpcProvider(getRpcUrlWithApiKey(rpcUrl))
const provider = new ethers.providers.StaticJsonRpcProvider(rpcUrl)
provider
.send("eth_chainId", [])
.then((hexChainId) => {
Expand Down
15 changes: 0 additions & 15 deletions apps/extension/src/ui/util/getRpcUrlWithApiKey.ts

This file was deleted.

0 comments on commit 02f64b2

Please sign in to comment.