mirror of
https://github.com/chatmail/core.git
synced 2026-05-20 07:16:31 +03:00
create_or_lookup_adhoc_group: move comment to the correct place
The comment is related to member list processing, not mailing list check.
This commit is contained in:
@@ -1230,10 +1230,6 @@ async fn create_or_lookup_adhoc_group(
|
|||||||
from_id: u32,
|
from_id: u32,
|
||||||
to_ids: &ContactIds,
|
to_ids: &ContactIds,
|
||||||
) -> Result<(ChatId, Blocked)> {
|
) -> Result<(ChatId, Blocked)> {
|
||||||
// if we're here, no grpid was found, check if there is an existing
|
|
||||||
// ad-hoc group matching the to-list or if we should and can create one
|
|
||||||
// (we do not want to heuristically look at the likely mangled Subject)
|
|
||||||
|
|
||||||
if mime_parser.is_mailinglist_message() {
|
if mime_parser.is_mailinglist_message() {
|
||||||
// XXX we could parse List-* headers and actually create and
|
// XXX we could parse List-* headers and actually create and
|
||||||
// manage a mailing list group, eventually
|
// manage a mailing list group, eventually
|
||||||
@@ -1244,6 +1240,10 @@ async fn create_or_lookup_adhoc_group(
|
|||||||
return Ok((ChatId::new(0), Blocked::Not));
|
return Ok((ChatId::new(0), Blocked::Not));
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// if we're here, no grpid was found, check if there is an existing
|
||||||
|
// ad-hoc group matching the to-list or if we should and can create one
|
||||||
|
// (we do not want to heuristically look at the likely mangled Subject)
|
||||||
|
|
||||||
let mut member_ids: Vec<u32> = to_ids.iter().copied().collect();
|
let mut member_ids: Vec<u32> = to_ids.iter().copied().collect();
|
||||||
if !member_ids.contains(&from_id) {
|
if !member_ids.contains(&from_id) {
|
||||||
member_ids.push(from_id);
|
member_ids.push(from_id);
|
||||||
|
|||||||
Reference in New Issue
Block a user