fixed slashed epoch (#1723)

This commit is contained in:
terence tsao 2019-02-26 14:12:06 -08:00 committed by Raul Jordan
parent c2ad89a8b6
commit 727adacb4b

View File

@ -227,7 +227,7 @@ func SlashValidator(state *pb.BeaconState, idx uint64) (*pb.BeaconState, error)
state.ValidatorBalances[whistleblowerIdx] += whistleblowerReward
state.ValidatorBalances[idx] -= whistleblowerReward
state.ValidatorRegistry[idx].SlashedEpoch = helpers.CurrentEpoch(state)
state.ValidatorRegistry[idx].SlashedEpoch = helpers.CurrentEpoch(state) + params.BeaconConfig().LatestSlashedExitLength
return state, nil
}