[Staking] Add Amount for Unstaking Funds
Closed this issue · 1 comments
daniel-wehbe commented
Description
The staking ADO has an Unstake message that undelegates tokens from the specified validator. Currently this message does not have an amount to specify how much funds to undelegate so it undelegates the total amount. If possible we would like to add the option to add an amount and if not specified would default to taking the maximum.
Also we might want to change the Claim message recipient to be of type Recipient instead of AndrAddr. This is to allow the rewards to be sent to another ADO which might be useful for some use cases:
Claim {
validator: Option<Addr>,
recipient: Option<AndrAddr>,
},
Acceptance Criteria
- Unstaking takes an optional amount field to specify the number of tokens to unstake
- Claim now has the option to send the rewards to another ADO (by using the Recipient struct instead of AndrAddr)
- Unit test to confirm functionality
joemonem commented
Did not replace AndrAddr
with Recipient
in the Claim
msg.