Skip to content

Commit

Permalink
fix deploying
Browse files Browse the repository at this point in the history
  • Loading branch information
rbajollari committed May 13, 2024
1 parent 285d42a commit 46d5695
Show file tree
Hide file tree
Showing 5 changed files with 13 additions and 11 deletions.
2 changes: 2 additions & 0 deletions .env.example
Original file line number Diff line number Diff line change
Expand Up @@ -8,3 +8,5 @@ OJO_CHAIN=ojo
OJO_ADDRESS=ojo1es9mhmnunh208ucwq8rlrl97hqulxrz8k37dcu
RESOLVE_WINDOW=7200
ASSET_LIMIT=5
PRICE_FEED_IMPLEMENTATION_CONTRACT_ADDRESS=0xD1077c12ba7C0ED41d288F5505af2Cb23bBD680a
CLONE_FACTORY_CONTRACT_ADDRESS=0x9AaE2ac2637B9f441d1537bBdCEB712854dd426B
4 changes: 2 additions & 2 deletions contracts/pricefeed/PriceFeed.sol
Original file line number Diff line number Diff line change
Expand Up @@ -9,9 +9,9 @@ import "../OjoTypes.sol";
/// @title Contract for calling Ojo's oracle contract with chainlink's AggregatorV3Interface implemented.
/// @author Ojo Network (https://docs.ojo.network/)
contract PriceFeed is Initializable, AggregatorV3Interface {
uint8 public priceFeedDecimals;
uint8 private priceFeedDecimals;

string public priceFeedDescription;
string private priceFeedDescription;

IOjo public immutable ojo;

Expand Down
6 changes: 3 additions & 3 deletions scripts/createPriceFeed.ts
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ import testnet_chains from '../testnet_chains.json';
import mainnet_chains from '../mainnet_chains.json';

async function main() {
const cloneFactoryAddress = process.env.CLONE_FACTORY_ADDRESS as string;
const cloneFactoryAddress = process.env.CLONE_FACTORY_CONTRACT_ADDRESS as string;
const priceFeedDecimals = 18;
const priceFeedDescription = "ETH";

Expand All @@ -14,9 +14,9 @@ async function main() {
throw new Error('Invalid private key. Make sure the PRIVATE_KEY environment variable is set.');
}

const mainnet = Boolean(process.env.MAINNET)
const mainnet = process.env.MAINNET as string
let evmChains = testnet_chains.map((chain) => ({ ...chain }));
if (mainnet === true) {
if (mainnet === "TRUE") {
evmChains = mainnet_chains.map((chain) => ({ ...chain }));
}

Expand Down
6 changes: 3 additions & 3 deletions scripts/deployCloneFactory.ts
Original file line number Diff line number Diff line change
Expand Up @@ -4,17 +4,17 @@ import testnet_chains from '../testnet_chains.json';
import mainnet_chains from '../mainnet_chains.json';

async function main () {
const priceFeedImplementation = process.env.PRICE_FEED_IMPLEMENTATION_ADDRESS;
const priceFeedImplementation = process.env.PRICE_FEED_IMPLEMENTATION_CONTRACT_ADDRESS;

const privateKey = process.env.PRIVATE_KEY;

if (!privateKey) {
throw new Error('Invalid private key. Make sure the PRIVATE_KEY environment variable is set.');
}

const mainnet = Boolean(process.env.MAINNET)
const mainnet = process.env.MAINNET as string
let evmChains = testnet_chains.map((chain) => ({ ...chain }));
if (mainnet === true) {
if (mainnet === "TRUE") {
evmChains = mainnet_chains.map((chain) => ({ ...chain }));
}

Expand Down
6 changes: 3 additions & 3 deletions scripts/deployPriceFeedImplementation.ts
Original file line number Diff line number Diff line change
Expand Up @@ -4,17 +4,17 @@ import testnet_chains from '../testnet_chains.json';
import mainnet_chains from '../mainnet_chains.json';

async function main() {
const ojoAddress = process.env.OJO_ADDRESS;
const ojoAddress = process.env.OJO_CONTRACT_ADDRESS;

const privateKey = process.env.PRIVATE_KEY;

if (!privateKey) {
throw new Error('Invalid private key. Make sure the PRIVATE_KEY environment variable is set.');
}

const mainnet = Boolean(process.env.MAINNET)
const mainnet = process.env.MAINNET as string
let evmChains = testnet_chains.map((chain) => ({ ...chain }));
if (mainnet === true) {
if (mainnet === "TRUE") {
evmChains = mainnet_chains.map((chain) => ({ ...chain }));
}

Expand Down

0 comments on commit 46d5695

Please sign in to comment.