-
Notifications
You must be signed in to change notification settings - Fork 11
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
fix: [RFR-01][RFR-03] unify the meaning of minAmountToConvert
Problem: With the evolution of the code, the meaning of the conversion threshold started to change. As a result, we ended up comparing the amount out (in tokens), balance of underlying * oracle price (in dollars), with minAmountToConvert. While in most cases these values would be close to each other as long as some stablecoin is used for the threshold, it might be problematic to set this threshold correctly, considering the potential slippage. Solution: Expect amountOutMin * base price to be greater than minAmountToConvert. Adjust the failing test accordingly.
- Loading branch information
Showing
2 changed files
with
53 additions
and
54 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters