mirror of
https://github.com/0glabs/0g-chain.git
synced 2024-12-26 00:05:18 +00:00
sync supply interest before ValidateBorrow (#798)
This commit is contained in:
parent
9fa83f0a1e
commit
be498c72f5
@ -34,6 +34,7 @@ func (k Keeper) Borrow(ctx sdk.Context, borrower sdk.AccAddress, coins sdk.Coins
|
||||
k.BeforeBorrowModified(ctx, existingBorrow)
|
||||
}
|
||||
|
||||
k.SyncSupplyInterest(ctx, borrower)
|
||||
k.SyncBorrowInterest(ctx, borrower)
|
||||
|
||||
// Validate borrow amount within user and protocol limits
|
||||
|
Loading…
Reference in New Issue
Block a user