rahul-kothari / hack-money-ape

For ETHGlobal's HackMoney hackathon
10 stars 1 forks source link

Add slippage protection for the number of base tokens that are spent #36

Closed mattiaslightstone closed 3 years ago

mattiaslightstone commented 3 years ago

Implemented as such:

Slippage tolerance will refer to the the movement of both the Yield Tokens Received and the Base Tokens Spent.

This means that 1% slippage will allow up to a 0.5% decrease in the number of YTs received, and 0.5% increase in the number of BTs spent.

This seems inelegant, but I'm not sure of the better way to do it.