From a24991906124de786185170f90de12465477bf46 Mon Sep 17 00:00:00 2001 From: Andras Schmelczer Date: Sat, 29 Mar 2025 09:41:33 +0000 Subject: [PATCH] Add comments --- backend/Cargo.toml | 2 +- backend/sync_server/src/app_state/broadcasts.rs | 2 ++ 2 files changed, 3 insertions(+), 1 deletion(-) diff --git a/backend/Cargo.toml b/backend/Cargo.toml index 7b0b3307..0dbad3aa 100644 --- a/backend/Cargo.toml +++ b/backend/Cargo.toml @@ -22,7 +22,7 @@ thiserror = { version = "1.0.66", default-features = false } codegen-units = 1 lto = true opt-level = 3 -strip="debuginfo" +strip="debuginfo" # Keep some info for better panics [workspace.lints.rust] unsafe_code = "forbid" diff --git a/backend/sync_server/src/app_state/broadcasts.rs b/backend/sync_server/src/app_state/broadcasts.rs index 76740a5e..9d2d2192 100644 --- a/backend/sync_server/src/app_state/broadcasts.rs +++ b/backend/sync_server/src/app_state/broadcasts.rs @@ -29,6 +29,8 @@ impl Broadcasts { tx.subscribe() } + /// Sent a document update to all clients subscribed to the vault. + /// We ignore & log failures. pub async fn send(&self, vault: VaultId, document: DocumentVersionWithoutContent) { let tx = self.get_or_create(vault).await;