diff options
Diffstat (limited to 'src/state/mod.rs')
| -rw-r--r-- | src/state/mod.rs | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/src/state/mod.rs b/src/state/mod.rs index 604f6ae..36dab9d 100644 --- a/src/state/mod.rs +++ b/src/state/mod.rs @@ -377,6 +377,16 @@ impl AppState { *self.closing.borrow() } + /// The kind of this node's document (`document::KIND`, or a set of events where + /// one carries its store). + pub(crate) fn kind(&self) -> &'static str { + #[cfg(feature = "federation")] + if self.holding.of_a_set() { + return self.holding.kind(); + } + crate::document::KIND + } + pub(crate) fn local_id(&self) -> &str { self.transport.local_id() } |
