Users cannot convert wUSDT to USDT on AaveDivaWrapper when Aave's USDT supply is fully borrowed, resulting in their inability to access liquidity or earn yields directly from their original investments (the yield goes to AaveDIVAWrapper), despite the pool being over. (USDT is used as an example)
Imagine a scenario where there is a pool with collateral token wUSDT.
AaveDivaWrapper earns a Yield from collateral tokens that are "sitting" in the pool. Imagine a scenario where the pool ends and the user withdraws
wUSDT from the pool. Additionally all of USDTs supply on Aave are borrowed, meaning that users who supplied the collateral cannot
withdraw it from Aave but they earn a very high interest due to internal logic of Aave. Due to the logic of withdraw on Aave, the user cannot swap theirs wUSDT for USDT (because all of the functions in AaveDivaWrapper that swap wTokens to USDT will revert) despite the pool being ended and all of the
high yield from underlying collateral of wUSDT is earned by AaveDivaWrapper, however now the users should have a possibillity to earn yield from
the underlying collateral. Because there is no function called redeemWTokenToAToken, users after the pool ends in this scenario are left with tokens which do not earn high yield
that protocol takes possiession of. This can last for a long time.
Users considering this scenario will prefer depositing to pools, where underlying collaterall is USDT not wTokens, because after the pool ends
they have access to their liquidity and can immedietly earn yield on these tokens, which is sometimes not possible using wTokens putting
users in a "loss", by not letting them earn any yield on Aave from their tokens. Because users will prefer using original Diva Donate not AaveDIVAWrapper, the protocol also will make less profits.
Manual Review
Implement a function that allows users to swap wTokens to aTokens, so after the pool ends they will have access to their liquidity and earn yield on it.
The contest is live. Earn rewards by submitting a finding.
This is your time to appeal against judgements on your submissions.
Appeals are being carefully reviewed by our judges.