Skip to content

Commit

Permalink
fix lint
Browse files Browse the repository at this point in the history
  • Loading branch information
mossid committed Jul 7, 2019
1 parent 83afdaf commit 21e0b15
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 5 deletions.
2 changes: 1 addition & 1 deletion x/ibc/02-client/tendermint/tests/valset.go
Original file line number Diff line number Diff line change
Expand Up @@ -84,7 +84,7 @@ type MockValidators []MockValidator

var _ sort.Interface = MockValidators{}

// TODO: differenciate power between the vals
// TODO: differentiate power between the vals
func NewMockValidators(num int, power int64) MockValidators {
res := make(MockValidators, num)
for i := range res {
Expand Down
5 changes: 1 addition & 4 deletions x/ibc/02-client/tendermint/types.go
Original file line number Diff line number Diff line change
Expand Up @@ -48,11 +48,8 @@ func (cs ConsensusState) Validate(cheader client.Header) (client.ConsensusState,
return nil, errors.New("invalid type")
}

nextvalset := cs.NextValidatorSet
nexthash := nextvalset.Hash()

if cs.Height == uint64(header.Height-1) {
nexthash = cs.NextValidatorSet.Hash()
nexthash := cs.NextValidatorSet.Hash()
if !bytes.Equal(header.ValidatorsHash, nexthash) {
return nil, lerr.ErrUnexpectedValidators(header.ValidatorsHash, nexthash)
}
Expand Down

0 comments on commit 21e0b15

Please sign in to comment.