Skip to content

Commit

Permalink
feat: cap
Browse files Browse the repository at this point in the history
  • Loading branch information
rhlsthrm committed Oct 24, 2024
1 parent f646e2e commit 46b5c14
Showing 1 changed file with 8 additions and 1 deletion.
9 changes: 8 additions & 1 deletion packages/contracts/tasks/chain-specific/fraxtal/markets.ts
Original file line number Diff line number Diff line change
Expand Up @@ -55,7 +55,7 @@ task("markets:fraxtal:set-cf", "deploy base market").setAction(async (_, { viem,
});

task("markets:fraxtal:set-caps", "Set supply and borrow caps for markets").setAction(async (_, { viem, run }) => {
const asset = assets.find((asset) => asset.symbol === assetSymbols.WETH);
const asset = assets.find((asset) => asset.symbol === assetSymbols.insfrxETH);
if (!asset) {
throw new Error("Asset not found");
}
Expand All @@ -74,4 +74,11 @@ task("markets:fraxtal:set-caps", "Set supply and borrow caps for markets").setAc
maxBorrow: asset.initialBorrowCap
});
}

if (asset.initialCf) {
await run("market:set:ltv", {
marketAddress: cToken,
ltv: asset.initialCf
});
}
});

0 comments on commit 46b5c14

Please sign in to comment.