style: fix clippy collapsible_if warnings in nvim-core

This commit is contained in:
Riz Ashraf committed 2026-09-22 06:07:50 +01:00
1 parent 148025c5a7
commit b2f15de58c
8 files changed
+105 -89

No files matched your search

+3 -6
View File
@@ -1,7 +1,7 @@
use crate::store::STORE_TABLE;
use redb::{Database, ReadableTable};
use std::path::Path;
use std::sync::Arc;
use redb::{Database, ReadableTable};
use crate::store::STORE_TABLE;
pub fn init_redb(base: &Path) -> Arc<Database> {
let redb_path = base.join("mcp_store.redb");
@@ -50,10 +50,7 @@ pub fn init_redb(base: &Path) -> Arc<Database> {
table
.insert(*key, data.as_slice())
.expect("Failed to insert migrated data");
let _ = std::fs::rename(
&json_path,
json_path.with_extension("json.migrated"),
);
let _ = std::fs::rename(&json_path, json_path.with_extension("json.migrated"));
}
}
}