RealToken-Community / dashboard-v2

https://dashboard.realtoken.community
5 stars 4 forks source link

RMM debt is not up to date #3

Closed ehpst closed 3 months ago

ehpst commented 1 year ago

Summary/RMM borrow is taken from TheGraph which does not take the most recent value. It would be better to get the value directly from the RMM contract.

NandyBa commented 1 year ago

@ehpst I have implemented the feature in the feature/rmm-debt-from-smart-contract branch. I recommend utilizing this only for a quicker response or if TheGraph fails to index the blockchain state accurately. Please consider merging this branch only if there is concrete evidence of an issue with TheGraph's indexing.

Update: It's seems that the current TheGraph implementation don't take into account interest. So this one is more accurate

NandyBa commented 1 year ago

For consistency I also add deposit xDAI amount using the same method.

NandyBa commented 1 year ago

Update: PR opened to solve the issue #19