diff --git a/lib/babe/verify.go b/lib/babe/verify.go index add58392a4..545ddd97e0 100644 --- a/lib/babe/verify.go +++ b/lib/babe/verify.go @@ -388,7 +388,7 @@ func (b *verifier) verifyPreRuntimeDigest(digest *types.PreRuntimeDigest) (scale authIdx = d.AuthorityIndex } - if len(b.authorities) <= int(authIdx) { + if uint64(len(b.authorities)) <= uint64(authIdx) { logger.Tracef("verifyPreRuntimeDigest invalid auth index %d, we have %d auths", authIdx, len(b.authorities)) return nil, ErrInvalidBlockProducerIndex