From 13cba9b0be736433d8ac44c0ef046cb001918a07 Mon Sep 17 00:00:00 2001 From: tv Date: Sat, 7 Nov 2026 22:35:09 +0100 Subject: store: keys_at tells no map from an empty one registry::exists counted any value at _continuum/users as a registry; keys_at answers None where there is no map, and its users (records, members, forget records, remakes) say what they make of it. Auth plan M1 (fix). --- src/remake/snapshot.rs | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'src/remake/snapshot.rs') diff --git a/src/remake/snapshot.rs b/src/remake/snapshot.rs index 157a28d..220989e 100644 --- a/src/remake/snapshot.rs +++ b/src/remake/snapshot.rs @@ -231,6 +231,7 @@ pub(crate) fn verify_document(doc: &Document, epoch: Epoch) -> Result Result { let generation = store::keys_at(doc, &meta::path(&[EPOCHS])) .map_err(|error| error.to_string())? + .unwrap_or_default() .iter() .filter_map(|key| key.parse::().ok()) .max(); @@ -295,7 +296,7 @@ pub(crate) fn build( Ok(()) | Err(StoreError::NotFound) => {} Err(error) => return Err(error.into()), } - let mut protocol_keys = store::keys_at(&base, &meta::path(&[]))?; + let mut protocol_keys = store::keys_at(&base, &meta::path(&[]))?.unwrap_or_default(); protocol_keys.sort(); for key in protocol_keys .into_iter() -- cgit v1.3.1