Skip to content
Snippets Groups Projects
Unverified Commit 45e23e16 authored by Sergey V's avatar Sergey V
Browse files

refactor: if raw_node.has_ready()

parent 1750001b
No related branches found
No related tags found
1 merge request!37refactor: if raw_node.has_ready()
Pipeline #3506 passed
......@@ -53,7 +53,9 @@ impl Node {
raw_node.tick();
}
on_ready(&mut raw_node, handle_committed_data);
if raw_node.has_ready() {
on_ready(&mut raw_node, handle_committed_data);
}
}
};
......@@ -75,10 +77,6 @@ impl Node {
}
fn on_ready(raft_group: &mut RawNode, handle_committed_data: fn(&[u8])) {
if !raft_group.has_ready() {
return;
}
tlog!(Debug, "vvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvv");
// Get the `Ready` with `RawNode::ready` interface.
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment