mirror of
https://github.com/pezkuwichain/pezkuwi-subxt.git
synced 2026-07-20 12:45:40 +00:00
Make sure to preserve backing votes (#6382)
* Guide updates * Consider more dead forks. * Ensure backing votes don't get overridden. * Fix spelling. * Fix comments. * Update node/primitives/src/lib.rs Co-authored-by: Tsvetomir Dimitrov <tsvetomir@parity.io> Co-authored-by: eskimor <eskimor@no-such-url.com> Co-authored-by: Tsvetomir Dimitrov <tsvetomir@parity.io>
This commit is contained in:
@@ -279,7 +279,7 @@ impl DisputeSender {
|
||||
Some(votes) => votes,
|
||||
};
|
||||
|
||||
let our_valid_vote = votes.valid.get(&our_index);
|
||||
let our_valid_vote = votes.valid.raw().get(&our_index);
|
||||
|
||||
let our_invalid_vote = votes.invalid.get(&our_index);
|
||||
|
||||
@@ -291,7 +291,7 @@ impl DisputeSender {
|
||||
} else if let Some(our_invalid_vote) = our_invalid_vote {
|
||||
// Get some valid vote as well:
|
||||
let valid_vote =
|
||||
votes.valid.iter().next().ok_or(JfyiError::MissingVotesFromCoordinator)?;
|
||||
votes.valid.raw().iter().next().ok_or(JfyiError::MissingVotesFromCoordinator)?;
|
||||
(valid_vote, (&our_index, our_invalid_vote))
|
||||
} else {
|
||||
// There is no vote from us yet - nothing to do.
|
||||
|
||||
Reference in New Issue
Block a user