Unstake() fails for getting insufficient assets from AssetManager#158
Unstake() fails for getting insufficient assets from AssetManager#158maxweng wants to merge 2 commits into
Conversation
UNI-1387 Unstake should fail if the amount withdrawal is not correct
Currently, the UserManager records the difference between the unstaking amount and the actual amount of tokens received from the underlying money markets but has the unstake() transaction goes thru anyways. E.g. https://optimistic.etherscan.io/tx/0x99a2e738b1ea04bc1b84474dfcd1318679e4397b96e34cc2525c634c53447609 But the problem jacob thinks is the end users won't know what happened if they receives a different amount than the one they ask for. So, jacob is proposing to have the unstake() transaction to fail altogether when the receiving token amount is different from the unstaking amount. |
Codecov Report
@@ Coverage Diff @@
## master #158 +/- ##
==========================================
- Coverage 82.78% 82.76% -0.02%
==========================================
Files 20 20
Lines 918 917 -1
Branches 174 174
==========================================
- Hits 760 759 -1
Misses 96 96
Partials 62 62
📣 We’re building smart automated test selection to slash your CI/CD build times. Learn more |
No description provided.