mirror of https://github.com/railgun-rs/actix-raft
parent
cdbaba3a02
commit
2d51ebcbf0
|
@ -3,6 +3,8 @@ changelog
|
|||
This changelog follows the patterns described here: https://keepachangelog.com/en/1.0.0/.
|
||||
|
||||
## [unreleased]
|
||||
### fixed
|
||||
- Fixed [#105](https://github.com/async-raft/async-raft/issues/105) where function `set_target_state` missing `else` condition.
|
||||
|
||||
## async-raft 0.6.0
|
||||
The big news for this release is that we are now based on Tokio 1.0! Big shoutout to @xu-cheng for doing all of the heavy lifting for the Tokio 1.0 update, along with many other changes which are part of this release.
|
||||
|
|
|
@ -254,8 +254,9 @@ impl<D: AppData, R: AppDataResponse, N: RaftNetwork<D>, S: RaftStorage<D, R>> Ra
|
|||
fn set_target_state(&mut self, target_state: State) {
|
||||
if target_state == State::Follower && !self.membership.contains(&self.id) {
|
||||
self.target_state = State::NonVoter;
|
||||
} else {
|
||||
self.target_state = target_state;
|
||||
}
|
||||
self.target_state = target_state;
|
||||
}
|
||||
|
||||
/// Get the next election timeout, generating a new value if not set.
|
||||
|
|
Loading…
Reference in New Issue