Skip to content

armgit / xerj

Public Imported from GitHub
0

AI search engine and MCP server for bots and agents. One Rust binary indexes code, docs, logs, JSONL/CSV and PDFs for BM25 full-text, vector and hybrid search, code search without grep, agent memory and RAG. Elasticsearch-compatible API; Corpus Hub serves hundreds of reference memory corpora.

style(xerj-autoindex): satisfy unnecessary_get_then_check in the #1224 test

xerj-org3d5059010c39
diff --git a/engine/crates/xerj-autoindex/src/sync.rs b/engine/crates/xerj-autoindex/src/sync.rs
index 2d2fe541c..dd89e25f0 100644
--- a/engine/crates/xerj-autoindex/src/sync.rs
+++ b/engine/crates/xerj-autoindex/src/sync.rs
@@ -1547,11 +1547,11 @@ mod tests {
assert!(pending
.apply_operation_state("other", "op-1", SyncOperationState::Started)
.is_err());
- assert!(pending.operation_states.get("op-1").is_none());
+ assert!(!pending.operation_states.contains_key("op-1"));
assert!(pending
.validate_operation_state("tx", "op-2", &SyncOperationState::Committed)
.is_err());
- assert!(pending.operation_states.get("op-2").is_none());
+ assert!(!pending.operation_states.contains_key("op-2"));
// A restructured operations list must not be answered from a stale
// index built for the old shape.