diff --git a/constellation/src/storage/mem_store.rs b/constellation/src/storage/mem_store.rs index cd00569..a109115 100644 --- a/constellation/src/storage/mem_store.rs +++ b/constellation/src/storage/mem_store.rs @@ -288,9 +288,9 @@ impl LinkReader for MemStorage { .enumerate() .filter_map(|(i, opt)| opt.as_ref().map(|v| (i, v))) .skip_while(|(linker_idx, _)| cursor.is_some_and(|c| *linker_idx < c.backward as usize)) - .filter(|(_, (did, _))| filter_dids.is_empty() || filter_dids.contains(&did)) + .filter(|(_, (did, _))| filter_dids.is_empty() || filter_dids.contains(did)) { - let Some(links) = data.links.get(&did).and_then(|m| { + let Some(links) = data.links.get(did).and_then(|m| { m.get(&RepoId { collection: collection.to_string(), rkey: rkey.clone(), diff --git a/constellation/src/storage/mod.rs b/constellation/src/storage/mod.rs index 2be5dae..30a2185 100644 --- a/constellation/src/storage/mod.rs +++ b/constellation/src/storage/mod.rs @@ -142,6 +142,7 @@ pub trait LinkReader: Clone + Send + Sync + 'static { fn get_all_record_counts(&self, _target: &str) -> Result>>; + #[allow(clippy::too_many_arguments)] fn get_many_to_many( &self, target: &str, diff --git a/constellation/src/storage/rocks_store.rs b/constellation/src/storage/rocks_store.rs index 3917026..0b5f0ba 100644 --- a/constellation/src/storage/rocks_store.rs +++ b/constellation/src/storage/rocks_store.rs @@ -1060,7 +1060,7 @@ impl LinkReader for RocksStorage { // if we have a full page, and we're inserting a *new* key less than // the current max, then we can evict the current max let mut should_evict = false; - let entry = grouped_counts.entry(fwd_target.clone()).or_insert_with(|| { + let entry = grouped_counts.entry(fwd_target).or_insert_with(|| { // this is a *new* key, so kick the max if we're full should_evict = page_is_full; Default::default()