state-res: Use HashSet::retain
This commit is contained in:
parent
1a4b7903b8
commit
91e6a1c65c
@ -91,9 +91,8 @@ where
|
|||||||
// synapse says `full_set = {eid for eid in full_conflicted_set if eid in event_map}`
|
// synapse says `full_set = {eid for eid in full_conflicted_set if eid in event_map}`
|
||||||
//
|
//
|
||||||
// Don't honor events we cannot "verify"
|
// Don't honor events we cannot "verify"
|
||||||
// TODO: BTreeSet::retain() when stable 1.53
|
auth_diff.retain(|id| fetch_event(id).is_some());
|
||||||
let all_conflicted =
|
let all_conflicted = auth_diff;
|
||||||
auth_diff.into_iter().filter(|id| fetch_event(id).is_some()).collect::<HashSet<_>>();
|
|
||||||
|
|
||||||
info!("full conflicted set: {}", all_conflicted.len());
|
info!("full conflicted set: {}", all_conflicted.len());
|
||||||
debug!("{:?}", all_conflicted);
|
debug!("{:?}", all_conflicted);
|
||||||
|
Loading…
x
Reference in New Issue
Block a user