I am working on fixing an issue within step.finance regarding the accurate display of deposited tokens
We were told that we were displaying the cTOKEN values instead of the actual Token values
I investigated this repo and found that we are basing our implementation off the example code here, and that the example code is also making the same mistake
I had to add missing markets via PR's #1 and #2
Then I also had to divide by the correct number of decimals to enable comparison with the UI
All the numbers are off by a little bit:
121,176,215 USDC vs. 135,776,401 USDC
654,264 SOL vs. 861,415 SOL
35,021,559 USDT vs. 35,588,186 USDT
etc.
I will continue with finding a fix via cTOKEN vs. Token conversion. If anyone could provide a hint it would be appreciated. I intend to provide the fix to this repo, as well as our solend integration
Edit: My PR #2 can be run and will print out numbers as seen in the attached image
I am working on fixing an issue within step.finance regarding the accurate display of deposited tokens
We were told that we were displaying the cTOKEN values instead of the actual Token values
I investigated this repo and found that we are basing our implementation off the example code here, and that the example code is also making the same mistake
I will continue with finding a fix via cTOKEN vs. Token conversion. If anyone could provide a hint it would be appreciated. I intend to provide the fix to this repo, as well as our solend integration
Edit: My PR #2 can be run and will print out numbers as seen in the attached image