Submitted by cmichel, also found by 0xRajeev
When withdrawing from the vault, one redeems yTokens for tokens, thus the token balance of the contract should increase after withdrawal.
But the contract subtracts the currentBalance from the previousBalance:
All vault withdrawals fail due to the integer underflow as the previousBalance is less than currentBalance. Users wont be able to get back their investment.
Recommend that It should return currentBalance > previousBalance ? currentBalance - previousBalance : 0
kamescg (PoolTogether) confirmed and patched:
