Skip to content

Commit

Permalink
CDP-454 fix stability fee display in onboarding
Browse files Browse the repository at this point in the history
  • Loading branch information
b-pmcg committed Oct 24, 2019
1 parent b8df55b commit a8e66ce
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 5 deletions.
8 changes: 6 additions & 2 deletions src/components/CDPCreateScreens/CDPCreateConfirmCDP.js
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,11 @@ const CDPCreateConfirmSummary = ({
const { lang } = useLanguage();
const [hasReadTOS, setHasReadTOS] = useState(false);

const { liquidationPenalty, liquidationRatio, rate } = selectedIlk.data;
const {
liquidationPenalty,
liquidationRatio,
stabilityFee
} = selectedIlk.data;
const { gemsToLock, daiToDraw } = cdpParams;
const { liquidationPrice, collateralizationRatio } = calcCDPParams({
ilkData: selectedIlk.data,
Expand All @@ -51,7 +55,7 @@ const CDPCreateConfirmSummary = ({
[lang.liquidation_ratio, `${liquidationRatio}%`],
[lang.liquidation_price, `$${liquidationPrice.toFixed(2)}`],
[lang.liquidation_penalty, `${liquidationPenalty}%`],
[lang.stability_fee, `${rate}%`]
[lang.stability_fee, `${stabilityFee}%`]
];
return (
<Box
Expand Down
6 changes: 3 additions & 3 deletions src/components/CDPCreateScreens/CDPCreateDeposit.js
Original file line number Diff line number Diff line change
Expand Up @@ -150,9 +150,9 @@ const CDPCreateDepositSidebar = ({
const {
liquidationPenalty,
liquidationRatio,
rate,
debtCeiling,
ilkDebtAvailable
ilkDebtAvailable,
stabilityFee
} = selectedIlk.data;
return (
<Grid gridRowGap="m">
Expand All @@ -164,7 +164,7 @@ const CDPCreateDepositSidebar = ({
[lang.liquidation_price, `$${liquidationPrice.toFixed(2)}`],
['Current Price', `$${getUsdPrice(selectedIlk.data).toFixed(2)}`],

[lang.stability_fee, `${rate}%`],
[lang.stability_fee, `${stabilityFee}%`],
[lang.liquidation_ratio, `${liquidationRatio}%`],
[lang.liquidation_penalty, `${liquidationPenalty}%`],
[lang.collateral_debt_ceiling, `${prettifyNumber(debtCeiling)} DAI`],
Expand Down

0 comments on commit a8e66ce

Please sign in to comment.