1
0
mirror of https://github.com/oceanprotocol/ocean.js.git synced 2024-11-26 20:39:05 +01:00

add PROVIDER_URL environment variable

This commit is contained in:
Miquel A. Cabot 2022-03-17 16:12:13 +01:00
parent aa9f52b83d
commit c92f263741

View File

@ -14,7 +14,9 @@ LoggerInstance.setLevel(LogLevel.Error)
export const web3 = new Web3(process.env.NODE_URI || configHelperNetworks[1].nodeUri)
export const getTestConfig = async (web3: Web3) => {
return new ConfigHelper().getConfig(await web3.eth.getChainId())
const config = new ConfigHelper().getConfig(await web3.eth.getChainId())
config.providerUri = process.env.PROVIDER_URL || config.providerUri
return config
}
export const getAddresses = () => {