move function to better place

This commit is contained in:
Sebastian Klähn
2023-01-30 12:30:51 +01:00
parent 41f45bd680
commit 061fd1dd2d

View File

@@ -604,16 +604,6 @@ async fn add_parts(
}
}
}
better_msg = better_msg.or(apply_group_changes(
context,
mime_parser,
sent_timestamp,
chat_id,
from_id,
to_ids,
)
.await?);
}
if chat_id.is_none() {
@@ -659,6 +649,21 @@ async fn add_parts(
apply_mailinglist_changes(context, mime_parser, chat_id).await?;
}
if let Some(chat_id) = chat_id {
if let Some(even_better_msg) = apply_group_changes(
context,
mime_parser,
sent_timestamp,
chat_id,
from_id,
to_ids,
)
.await?
{
better_msg = Some(even_better_msg)
}
}
// if contact renaming is prevented (for mailinglists and bots),
// we use name from From:-header as override name
if prevent_rename {