Why `fundsFree` calculation deducts `feeReserve` twice?
Closed this issue · 1 comments
frankli-dev commented
let fundsReserved = planckToUnit(edReserved.plus(feeReserve), units);
const fundsFree = planckToUnit(
BigNumber.max(
allTransferOptions.freeBalance
.minus(fundsReserved)
.minus(feeReserve)
.minus(fundsLockedPlank),
0
),
units
);
Looks like it deducts feeReserve
twice.
fundsReserved = edReserved + feeReserve
fundsFree = freeBalance - fundsReserved - feeReserve
= freeBalance - (edReserved + feeReserve) - feeReserve
Anyone can help me to understand why we deduct feeReserve
twice?
Best regards,