state-res: Remove pointless .unwrap()
This commit is contained in:
parent
dc842f028f
commit
a3707b1a3a
@ -614,9 +614,7 @@ impl StateResolution {
|
|||||||
F: Fn(&EventId) -> Option<Arc<E>>,
|
F: Fn(&EventId) -> Option<Arc<E>>,
|
||||||
{
|
{
|
||||||
let mut state = vec![event_id.clone()];
|
let mut state = vec![event_id.clone()];
|
||||||
while !state.is_empty() {
|
while let Some(eid) = state.pop() {
|
||||||
// We just checked if it was empty so unwrap is fine
|
|
||||||
let eid = state.pop().unwrap();
|
|
||||||
graph.entry(eid.clone()).or_insert(hashset![]);
|
graph.entry(eid.clone()).or_insert(hashset![]);
|
||||||
// Prefer the store to event as the store filters dedups the events
|
// Prefer the store to event as the store filters dedups the events
|
||||||
for aid in &fetch_event(&eid).map(|ev| ev.auth_events()).unwrap_or_default() {
|
for aid in &fetch_event(&eid).map(|ev| ev.auth_events()).unwrap_or_default() {
|
||||||
|
Loading…
x
Reference in New Issue
Block a user