mirror of
https://github.com/meilisearch/meilisearch.git
synced 2024-11-22 10:07:40 +08:00
Fix issue with Replace document method when adding and deleting a document in the same batch
This commit is contained in:
parent
8e5b1a3ec1
commit
40dd25d6b2
@ -310,10 +310,10 @@ impl MergeChanges for MergeDocumentForReplacement {
|
||||
}
|
||||
Some(InnerDocOp::Deletion) => {
|
||||
return if is_new {
|
||||
Ok(None)
|
||||
} else {
|
||||
let deletion = Deletion::create(docid, external_doc);
|
||||
Ok(Some(DocumentChange::Deletion(deletion)))
|
||||
} else {
|
||||
Ok(None)
|
||||
};
|
||||
}
|
||||
None => unreachable!("We must not have empty set of operations on a document"),
|
||||
|
Loading…
Reference in New Issue
Block a user