issues
search
Kava-Labs
/
kava
DeFi for Crypto.
Apache License 2.0
439
stars
364
forks
source link
fix(x/precisebank): Ensure exact reserve balance on integer carry when minting
#1932
Closed
drklee3
closed
2 months ago
drklee3
commented
2 months ago
Description
Fix reserve minting an extra coin when the recipient module both carries fractional over to integer balance AND remainder is insufficient.
Adjusts fractional carry to simply send from reserve, instead of doing an additional mint.
Add invariant to ensure reserve matches exactly with fractional balances + remainder, failing on both insufficient and excess funds.
Description