osmosis-labs / isotonic

Smart Contracts for the Lendex Protocol
MIT License
1 stars 0 forks source link

Simulate interest payments on query #103

Closed uint closed 2 years ago

uint commented 2 years ago

Closes #56

I pulled out the interest calculation stuff into an immutable calculate_interest function. Now it's used for both charging and queries.

This PR handles including interest calculations in these queries:

Let me know if I missed something.

uint commented 2 years ago

Will rebase in a few.

uint commented 2 years ago

Math checks out, although I'd still rather have @ethanfrey to confirm this just in case. Because bug here is an original design - maybe there was reason for it.

Did you mean this one? https://github.com/confio/isotonic/pull/109

ueco-jb commented 2 years ago

Yup, having opened two reviews at same time. :man_shrugging: