diff --git a/bobbin/crates/edge-index/src/lib.rs b/bobbin/crates/edge-index/src/lib.rs index b92492b1f..bb16d98cf 100644 --- a/bobbin/crates/edge-index/src/lib.rs +++ b/bobbin/crates/edge-index/src/lib.rs @@ -636,7 +636,6 @@ pub struct EdgeStore { source_collections: SccMap, RuntimeHasher>, issue_counts: StateViewIndex, pull_counts: StateViewIndex, - source_collections: SccMap, RuntimeHasher>, hasher: RuntimeHasher, writer: Mutex<()>, } @@ -655,7 +654,6 @@ impl EdgeStore { source_collections: SccMap::with_hasher(hasher.clone()), issue_counts: StateViewIndex::new(hasher.clone()), pull_counts: StateViewIndex::new(hasher.clone()), - source_collections: SccMap::with_hasher(hasher.clone()), hasher, writer: Mutex::new(()), } diff --git a/bobbin/crates/xrpc/src/lib.rs b/bobbin/crates/xrpc/src/lib.rs index 1616ff944..b4df074f1 100644 --- a/bobbin/crates/xrpc/src/lib.rs +++ b/bobbin/crates/xrpc/src/lib.rs @@ -2938,54 +2938,6 @@ async fn resolve_mini_doc( async fn get_coverage(State(state): State) -> Json { Json(state.coverage.snapshot().into()) } - -#[derive(Deserialize)] -#[allow(dead_code)] -struct ListRecipientsQuery { - subject: String, - collection: Option, -} - -#[derive(Serialize)] -struct ListRecipientsResponse { - dids: Vec, -} - -async fn list_recipients( - State(state): State, - XrpcQuery(q): XrpcQuery, -) -> Result, XrpcError> { - use std::collections::BTreeSet; - - let subject_ref = if let Ok(uri) = AtUri::::new_owned(&q.subject) { - SubjectRef::Uri(uri) - } else if let Ok(did) = Did::::new_owned(&q.subject) { - SubjectRef::Did(did) - } else { - return Err(XrpcError::InvalidParams( - "subject must be an at-uri or did".into(), - )); - }; - - let key = EdgeKey::new(nsid_static("sh.tangled.feed.subscription"), subject_ref); - let sources = state.edges.sources_for(&key); - - // NOTE: collection filtering intentionally disabled. - // All subscribers are returned regardless of their stored collection filter. - let filtered = sources; - let mut seen = BTreeSet::new(); - let mut dids = Vec::new(); - for src in &filtered { - if let Some(did) = owner_did_from_aturi(src) { - if seen.insert(did.to_string()) { - dids.push(did.to_string()); - } - } - } - - Ok(Json(ListRecipientsResponse { dids })) -} - // enough for a write to travel pds -> relay -> indexer -> bobbin, plus slack // for a slow hop const AWAIT_RECORD_TIMEOUT: Duration = Duration::from_secs(5);