Skip to content

Commit

Permalink
feat: deploy OneJumpOralce with redstone if feed is referred by asset
Browse files Browse the repository at this point in the history
  • Loading branch information
simonzg committed Jul 8, 2024
1 parent c6a841c commit fd1a67a
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions deploy/1-deploy-oracles.ts
Original file line number Diff line number Diff line change
Expand Up @@ -208,7 +208,7 @@ const func: DeployFunction = async function ({ getNamedAccounts, deployments, ne
throw new Error(`address for token ${asset.denominatedBy} must be configured in ADDRESSES`);
}

const denominator = ADDRESSES[networkName][asset.denominatedBy];
const denominator = ADDRESSES[networkName][`${asset.token}/${asset.denominatedBy}`];
if (chainlinkFeed[networkName] && chainlinkFeed[networkName][asset.denominatedBy]) {
const chainlinkOracle = await ethers.getContract(contractName);
const oneJumpName = `OneJumpOracle_${asset.denominatedBy}_Chainlink`;
Expand All @@ -226,7 +226,8 @@ const func: DeployFunction = async function ({ getNamedAccounts, deployments, ne
}
oneJumpNames[oneJumpName] = true;
}
if (redstoneFeed[networkName] && redstoneFeed[networkName][asset.denominatedBy]) {

if (redstoneFeed[networkName] && redstoneFeed[networkName][`${asset.token}/${asset.denominatedBy}`]) {
const redstoneOracle = await ethers.getContract("RedStoneOracle");
const oneJumpName = `OneJumpOracle_${asset.denominatedBy}_RedStone`;
if (!oneJumpNames[oneJumpName]) {
Expand Down

0 comments on commit fd1a67a

Please sign in to comment.