Skip to content

Commit

Permalink
fix: show more decimals
Browse files Browse the repository at this point in the history
  • Loading branch information
sendra committed Jul 17, 2024
1 parent 5810ae7 commit 2b23d7d
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/reports/reserve.ts
Original file line number Diff line number Diff line change
Expand Up @@ -15,9 +15,9 @@ export function renderReserveValue<T extends keyof AaveV3Reserve>(
if (key === 'debtCeiling')
return `${Number(formatUnits(BigInt(reserve[key]), 2)).toLocaleString('en-US')} $`;
if (['liquidityIndex', 'variableBorrowIndex'].includes(key))
return `${Number(formatUnits(BigInt(reserve[key]), 27)).toLocaleString('en-US')}`;
return `${Number(formatUnits(BigInt(reserve[key]), 20)).toLocaleString('en-US')}`;
if (['currentLiquidityRate', 'currentVariableBorrowRate'].includes(key))
return `${Number(formatUnits(BigInt(reserve[key]), 25)).toLocaleString('en-US')} %`;
return `${Number(formatUnits(BigInt(reserve[key]), 20)).toLocaleString('en-US')} %`;
if (key === 'liquidationBonus')
return reserve[key] === 0 ? '0 %' : `${((reserve[key] as number) - 10000) / 100} %`;
if (key === 'interestRateStrategy')
Expand Down

0 comments on commit 2b23d7d

Please sign in to comment.