Skip to content

Commit

Permalink
nit: code readability (#3961)
Browse files Browse the repository at this point in the history
  • Loading branch information
colin-axner authored Jun 26, 2023
1 parent b41d596 commit 6fcedca
Showing 1 changed file with 2 additions and 5 deletions.
7 changes: 2 additions & 5 deletions testing/chain.go
Original file line number Diff line number Diff line change
Expand Up @@ -472,9 +472,6 @@ func (chain *TestChain) CreateTMClientHeader(chainID string, blockHeight int64,
)
require.NotNil(chain.TB, tmValSet)

vsetHash := tmValSet.Hash()
nextValHash := nextVals.Hash()

tmHeader := tmtypes.Header{
Version: tmprotoversion.Consensus{Block: tmversion.BlockProtocol, App: 2},
ChainID: chainID,
Expand All @@ -483,8 +480,8 @@ func (chain *TestChain) CreateTMClientHeader(chainID string, blockHeight int64,
LastBlockID: MakeBlockID(make([]byte, tmhash.Size), 10_000, make([]byte, tmhash.Size)),
LastCommitHash: chain.App.LastCommitID().Hash,
DataHash: tmhash.Sum([]byte("data_hash")),
ValidatorsHash: vsetHash,
NextValidatorsHash: nextValHash,
ValidatorsHash: tmValSet.Hash(),
NextValidatorsHash: nextVals.Hash(),
ConsensusHash: tmhash.Sum([]byte("consensus_hash")),
AppHash: chain.CurrentHeader.AppHash,
LastResultsHash: tmhash.Sum([]byte("last_results_hash")),
Expand Down

0 comments on commit 6fcedca

Please sign in to comment.