diff --git a/action/protocol/staking/protocol.go b/action/protocol/staking/protocol.go index 85940effa8..35dfc223b6 100644 --- a/action/protocol/staking/protocol.go +++ b/action/protocol/staking/protocol.go @@ -494,10 +494,6 @@ func (p *Protocol) isActiveCandidate(ctx context.Context, csr CandidateStateRead if address.Equal(vb.Owner, cand.Owner) { return true, nil } - // bucket is not endorsed to the candidate - if !address.Equal(vb.Candidate, cand.Owner) { - return false, nil - } esr := NewEndorsementStateReader(csr.SR()) endorse, err := esr.Get(cand.SelfStakeBucketIdx) switch { @@ -513,6 +509,7 @@ func (p *Protocol) isActiveCandidate(ctx context.Context, csr CandidateStateRead return false, err default: // endorsement does not exist + return false, errors.New("endorsement does not exist") } return true, nil }