Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Minor: removed unused "disableViewChange" #4699

Merged
merged 1 commit into from
Jul 3, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 0 additions & 2 deletions consensus/consensus.go
Original file line number Diff line number Diff line change
Expand Up @@ -119,8 +119,6 @@ type Consensus struct {
host p2p.Host
// MessageSender takes are of sending consensus message and the corresponding retry logic.
msgSender *MessageSender
// If true, this consensus will not propose view change.
disableViewChange bool
// Have a dedicated reader thread pull from this chan, like in node
SlashChan chan slash.Record
// How long in second the leader needs to wait to propose a new block.
Expand Down
2 changes: 1 addition & 1 deletion consensus/view_change.go
Original file line number Diff line number Diff line change
Expand Up @@ -231,7 +231,7 @@ func createTimeout() map[TimeoutType]*utils.Timeout {

// startViewChange start the view change process
func (consensus *Consensus) startViewChange() {
if consensus.disableViewChange || consensus.isBackup {
if consensus.isBackup {
return
}

Expand Down