Function: redelegate(uint256 _fromValidatorId, uint256 _toValidatorId, uint256 _amount)
Allows the stake manager to redelegate.
Inputs
_fromValidatorIdControl: Fully controlled by the stake manager.
Constraints: None.
Impact: The validator to redelegate from.
_toValidatorIdControl: Fully controlled by the stake manager.
Constraints: None.
Impact: The validator to redelegate to.
_amountControl: Fully controlled by the stake manager.
Constraints: None.
Impact: The amount to redelegate.
Branches and code coverage (including function calls)
Intended branches
Should call
migrateDelegationon the gov stake manager with the given parameters.
Negative behavior
Should not be callable by anyone other than the stake manager. Ensured through
onlyStakeManager.
Function call analysis
govStakeManager.migrateDelegation(_fromValidatorId, _toValidatorId, _amount)What is controllable?
fromValidatorId,toValidatorId, andamount.If return value controllable, how is it used and how can it go wrong? N/A.
What happens if it reverts, reenters, or does other unusual control flow? Then the redelegate will fail.