mirror of
https://github.com/chatmail/core.git
synced 2026-05-08 17:36:29 +03:00
fix: ignore parent message if message references itself
When there are no parent references, Delta Chat inserts Message-ID into References. Such references should be ignored because otherwise fully downloaded message may be assigned to the same chat as previously incorrectly assigned partially downloaded message. Fixes receive_imf::tests::test_create_group_with_big_msg
This commit is contained in:
@@ -703,7 +703,9 @@ async fn add_parts(
|
|||||||
better_msg = Some(stock_str::msg_location_enabled_by(context, from_id).await);
|
better_msg = Some(stock_str::msg_location_enabled_by(context, from_id).await);
|
||||||
}
|
}
|
||||||
|
|
||||||
let parent = get_parent_message(context, mime_parser).await?;
|
let parent = get_parent_message(context, mime_parser)
|
||||||
|
.await?
|
||||||
|
.filter(|p| Some(p.id) != replace_msg_id);
|
||||||
|
|
||||||
let is_dc_message = if mime_parser.has_chat_version() {
|
let is_dc_message = if mime_parser.has_chat_version() {
|
||||||
MessengerMessage::Yes
|
MessengerMessage::Yes
|
||||||
|
|||||||
Reference in New Issue
Block a user