This does what it says on the box - currently, we do not consider opportunities with only undelegations to be active in selectAggregatedEarnUserStakingOpportunitiesIncludeEmpty.
This accidentally "works" on prod currently as most users would either have a staking balance or rewards for most opportunities, but e.g unstaking FOXy with delayed 14 days unstake, and not having a staking balance
anymore will currently rug the opportunity, which will not display.
Pull Request Type
[x] :bug: Bug fix (Non-breaking Change: Fixes an issue)
What protocols, transaction types or contract interactions might be affected by this PR?
None
Testing
Either test with a user that has an unstaking balance but no staking one for FOXy or
Get the address of any user that has FOXy unstaking (regardless of whether or not they have a balance) and revert the revert of the monkey patch in 602d0cb9c566a63f134092d6e2b2d3fc5d533799.
Max's 0x55 address can be used if going the second route
Ensure FOXy is currently being displayed as an active opportunity in /earn
Engineering
^
Operations
^
Screenshots (if applicable)
With the monkey patch of 0 balance in, but not the fix
Description
This does what it says on the box - currently, we do not consider opportunities with only undelegations to be active in
selectAggregatedEarnUserStakingOpportunitiesIncludeEmpty
. This accidentally "works" on prod currently as most users would either have a staking balance or rewards for most opportunities, but e.g unstaking FOXy with delayed 14 days unstake, and not having a staking balance anymore will currently rug the opportunity, which will not display.Pull Request Type
Issue (if applicable)
closes https://github.com/shapeshift/web/issues/6776
Risk
None
Testing
Engineering
Operations
Screenshots (if applicable)