aboutsummaryrefslogtreecommitdiffstats
path: root/src/access/strict.rs
diff options
context:
space:
mode:
authortv <tv@krebsco.de>2026-11-29 03:21:43 +0000
committertv <tv@krebsco.de>2026-11-29 03:21:43 +0000
commite63d30c2581033a85489b10c3f5b252fdbb5049e (patch)
tree5f4e6f65f1cecfb32f841e7ad7d9d106aeb69b20 /src/access/strict.rs
parent9188fa6e13ea7facfab5fb6f55bf26444ec2c01e (diff)
state: plain writes take a view to write, Automerge's are asked for as such
AppState::mutate_doc, mutate_doc_registering and mutate_doc_by hand what they are given a document::view::Write: the member registry, the users, sessions, forgetting and bootstrap write through them, and take whatever kind of document gives it. AppState::mutate_doc_for is for what asks more of an Automerge document than values at paths (the store's API, a remake's host, a store's events), and gives the heads after the write. What reads a view takes one of any size (dyn Write among them).
Diffstat (limited to 'src/access/strict.rs')
-rw-r--r--src/access/strict.rs6
1 files changed, 3 insertions, 3 deletions
diff --git a/src/access/strict.rs b/src/access/strict.rs
index 9857bed..0aac192 100644
--- a/src/access/strict.rs
+++ b/src/access/strict.rs
@@ -95,9 +95,9 @@ pub(crate) fn digest(value: &JsonValue) -> String {
/// The places values are signed in `doc` (`envelope::signed_paths`, `*` as `doc` has
/// them) that hold one, with it, as the store reads it.
-pub(crate) fn held(doc: &impl Read) -> Vec<(Vec<String>, JsonValue)> {
+pub(crate) fn held(doc: &(impl Read + ?Sized)) -> Vec<(Vec<String>, JsonValue)> {
fn expand(
- doc: &impl Read,
+ doc: &(impl Read + ?Sized),
pattern: &[String],
at: Vec<String>,
out: &mut Vec<(Vec<String>, JsonValue)>,
@@ -135,7 +135,7 @@ pub(crate) fn held(doc: &impl Read) -> Vec<(Vec<String>, JsonValue)> {
/// held at a signed place now, the policy `policy`, for `user` to look over and sign at
/// `at`. Its exact line.
pub(crate) fn manifest_of(
- doc: &impl Read,
+ doc: &(impl Read + ?Sized),
swarm: &str,
epoch: crate::document::replica::EpochRecord,
base: &[crate::document::ChangeHash],