Fixed missing "waitForTx"

This commit is contained in:
Zer0dot 2021-02-18 16:50:15 -05:00
parent a0dbf13d60
commit f44879e625

View File

@ -48,23 +48,17 @@ task('full:deploy-oracles', 'Deploy oracles for dev enviroment')
};
const [tokens, aggregators] = getPairsTokenAggregator(tokensToWatch, chainlinkAggregators);
// const aaveOracle = notFalsyOrZeroAddress(aaveOracleAddress)
// ? await getAaveOracle(aaveOracleAddress)
// : await deployAaveOracle(
// [tokens, aggregators, fallbackOracleAddress, await getWethAddress(poolConfig)],
// verify
// );
let aaveOracle: AaveOracle;
if (notFalsyOrZeroAddress(aaveOracleAddress)) {
aaveOracle = await getAaveOracle(aaveOracleAddress);
await aaveOracle.setAssetSources(tokens, aggregators);
await waitForTx(await aaveOracle.setAssetSources(tokens, aggregators));
} else {
aaveOracle = await deployAaveOracle(
[tokens, aggregators, fallbackOracleAddress, await getWethAddress(poolConfig)],
verify
);
}
const lendingRateOracle = notFalsyOrZeroAddress(lendingRateOracleAddress)
? await getLendingRateOracle(lendingRateOracleAddress)
: await deployLendingRateOracle(verify);