Skip to content

Commit

Permalink
Merge pull request #399 from tangem/bugfix/AND-5540_removed_infura_fr…
Browse files Browse the repository at this point in the history
…om_near

AND-5540 Finally removed Infura provider from NEAR
  • Loading branch information
kozarezvlad authored Dec 11, 2023
2 parents 94816e7 + 138d8f1 commit a1cc327
Showing 1 changed file with 0 additions and 8 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -21,8 +21,6 @@ internal object NearWalletManagerAssembly : WalletManagerAssembly<NearWalletMana
add(createNearJsonRpcProvider(isTestNet = false))
config.nowNodeCredentials?.apiKey.letNotBlank { add(createNowNodeJsonRpcProvider(it)) }
config.getBlockCredentials?.near?.jsonRpc.letNotBlank { add(createGetBlockJsonRpcProvider(it)) }
// temporarily exclude before AND-5171 fix
// config.infuraProjectId?.letNotBlank { add(getInfuraProvider(it)) }
}
}
val txBuilder = NearTransactionBuilder(wallet.publicKey)
Expand All @@ -49,10 +47,4 @@ internal object NearWalletManagerAssembly : WalletManagerAssembly<NearWalletMana
return NearJsonRpcNetworkProvider(baseUrl, nearApi)
}

private fun getInfuraProvider(infuraProjectId: String): NearJsonRpcNetworkProvider {
val baseUrl = "https://near-mainnet.infura.io/"
val nearApi = createRetrofitInstance("${baseUrl}v3/").create(NearApi::class.java)
return NearJsonRpcNetworkProvider(baseUrl, nearApi, infuraProjectId)
}

}

0 comments on commit a1cc327

Please sign in to comment.