diff --git a/.changeset/nervous-donkeys-decide.md b/.changeset/nervous-donkeys-decide.md new file mode 100644 index 0000000000..42098aed24 --- /dev/null +++ b/.changeset/nervous-donkeys-decide.md @@ -0,0 +1,5 @@ +--- +"@venusprotocol/evm": patch +--- + +use 6 decimal points in returned value of convertFactorFromSmartContract utility function diff --git a/apps/evm/src/utilities/convertFactorFromSmartContract.ts b/apps/evm/src/utilities/convertFactorFromSmartContract.ts index e30a73144b..a853061403 100644 --- a/apps/evm/src/utilities/convertFactorFromSmartContract.ts +++ b/apps/evm/src/utilities/convertFactorFromSmartContract.ts @@ -3,6 +3,6 @@ import BigNumber from 'bignumber.js'; import { COMPOUND_MANTISSA } from 'constants/compoundMantissa'; const convertFactorFromSmartContract = ({ factor }: { factor: BigNumber }) => - new BigNumber(factor).dividedBy(COMPOUND_MANTISSA).dp(2).toNumber(); + new BigNumber(factor).dividedBy(COMPOUND_MANTISSA).dp(6).toNumber(); export default convertFactorFromSmartContract;