Missed a min in slashing
This commit is contained in:
parent
0c5358c267
commit
1433b61a92
|
@ -202,10 +202,7 @@ func (k Keeper) slashRedelegation(ctx sdk.Context, validator types.Validator, re
|
|||
// Possible since the redelegation may already
|
||||
// have been slashed, and slash amounts are calculated
|
||||
// according to stake held at time of infraction
|
||||
redelegationSlashAmount := slashAmount
|
||||
if redelegationSlashAmount.GT(redelegation.Balance.Amount) {
|
||||
redelegationSlashAmount = redelegation.Balance.Amount
|
||||
}
|
||||
redelegationSlashAmount := sdk.MinInt(slashAmount, redelegation.Balance.Amount)
|
||||
|
||||
// Update redelegation if necessary
|
||||
if !redelegationSlashAmount.IsZero() {
|
||||
|
|
Loading…
Reference in New Issue