fix(elasticsearch): preserve legacy type on delete
This commit is contained in:
9 files changed
+85
-42
No files matched your search
@@ -147,15 +147,17 @@ pub async fn document_delete_document(
|
||||
collection: String,
|
||||
id: String,
|
||||
routing: Option<String>,
|
||||
document_type: Option<String>,
|
||||
) -> Result<u64, String> {
|
||||
ensure_connection_writable(&state, &connection_id, "Delete").await?;
|
||||
dbx_core::document_ops::delete_document_core(
|
||||
dbx_core::document_ops::delete_document_core_with_type(
|
||||
&state,
|
||||
&connection_id,
|
||||
&database,
|
||||
&collection,
|
||||
&id,
|
||||
routing.as_deref(),
|
||||
document_type.as_deref(),
|
||||
)
|
||||
.await
|
||||
}
|
||||
|
||||
@@ -467,8 +467,16 @@ pub async fn mongo_delete_document(
|
||||
id: String,
|
||||
routing: Option<String>,
|
||||
) -> Result<u64, String> {
|
||||
crate::commands::document_cmd::document_delete_document(state, connection_id, database, collection, id, routing)
|
||||
.await
|
||||
crate::commands::document_cmd::document_delete_document(
|
||||
state,
|
||||
connection_id,
|
||||
database,
|
||||
collection,
|
||||
id,
|
||||
routing,
|
||||
None,
|
||||
)
|
||||
.await
|
||||
}
|
||||
|
||||
#[tauri::command]
|
||||
|
||||
Reference in new issue
Block a user