opt maybe_update_best_child_and_descendant
: remove an impossible case (#4583)
Here `child.weight == best_child.weight` is impossible since it's already checked [above](dfcb3363c7/consensus/proto_array/src/proto_array.rs (L878)
).
This commit is contained in:
parent
ca050053bf
commit
dfab24bf92
@ -884,7 +884,7 @@ impl ProtoArray {
|
|||||||
}
|
}
|
||||||
} else {
|
} else {
|
||||||
// Choose the winner by weight.
|
// Choose the winner by weight.
|
||||||
if child.weight >= best_child.weight {
|
if child.weight > best_child.weight {
|
||||||
change_to_child
|
change_to_child
|
||||||
} else {
|
} else {
|
||||||
no_change
|
no_change
|
||||||
|
Loading…
Reference in New Issue
Block a user