Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

The amount of supply or borrowed assets can be outdated #592

Open
MerlinEgalite opened this issue Jan 24, 2024 · 0 comments
Open

The amount of supply or borrowed assets can be outdated #592

MerlinEgalite opened this issue Jan 24, 2024 · 0 comments

Comments

@MerlinEgalite
Copy link

MerlinEgalite commented Jan 24, 2024

const liquidity = position.market.totalSupplyAssets.minus(position.market.totalBorrowAssets)

The onchain getters do not take into account the accrued interest since the last update. This does not have implication in this line since supply and borrow increases at the same speed so the difference would be the same

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant