Skip to content

Commit

Permalink
fix: enable to join existing network with State Sync (#514)
Browse files Browse the repository at this point in the history
* Remove `SelectProposer`

* Remove `validators`

* fix maverick
  • Loading branch information
ulbqb authored Dec 1, 2022
1 parent 63ec829 commit 357b3d7
Show file tree
Hide file tree
Showing 2 changed files with 0 additions and 4 deletions.
2 changes: 0 additions & 2 deletions consensus/state.go
Original file line number Diff line number Diff line change
Expand Up @@ -666,7 +666,6 @@ func (cs *State) updateToState(state sm.State) {
}

// Reset fields based on state.
validators := state.Validators
voters := state.Voters

switch {
Expand Down Expand Up @@ -727,7 +726,6 @@ func (cs *State) updateToState(state sm.State) {
cs.CommitRound = -1
cs.LastVoters = state.LastVoters
cs.TriggeredTimeoutPrecommit = false
cs.Proposer = validators.SelectProposer(state.LastProofHash, cs.Height, cs.Round)

cs.state = state

Expand Down
2 changes: 0 additions & 2 deletions test/maverick/consensus/state.go
Original file line number Diff line number Diff line change
Expand Up @@ -858,7 +858,6 @@ func (cs *State) updateToState(state sm.State) {
}

// Reset fields based on state.
validators := state.Validators
voters := state.Voters

switch {
Expand Down Expand Up @@ -915,7 +914,6 @@ func (cs *State) updateToState(state sm.State) {
cs.CommitRound = -1
cs.LastVoters = state.LastVoters
cs.TriggeredTimeoutPrecommit = false
cs.Proposer = validators.SelectProposer(state.LastProofHash, cs.Height, cs.Round)

cs.state = state

Expand Down

0 comments on commit 357b3d7

Please sign in to comment.