mirror of
https://github.com/chatmail/core.git
synced 2026-05-02 21:06:31 +03:00
fix: BCC-to-self even if server deletion is set to "at once"
This commit is contained in:
14
src/chat.rs
14
src/chat.rs
@@ -2751,10 +2751,18 @@ pub(crate) async fn create_send_msg_jobs(context: &Context, msg: &mut Message) -
|
|||||||
let from = context.get_primary_self_addr().await?;
|
let from = context.get_primary_self_addr().await?;
|
||||||
let lowercase_from = from.to_lowercase();
|
let lowercase_from = from.to_lowercase();
|
||||||
|
|
||||||
// Send BCC to self if it is enabled and we are not going to
|
// Send BCC to self if it is enabled.
|
||||||
// delete it immediately. `from` must be the last addr, see `receive_imf_inner()` why.
|
//
|
||||||
|
// Previous versions of Delta Chat did not send BCC self
|
||||||
|
// if DeleteServerAfter was set to immediately delete messages
|
||||||
|
// from the server. This is not the case anymore
|
||||||
|
// because BCC-self messages are also used to detect
|
||||||
|
// that message was sent if SMTP server is slow to respond
|
||||||
|
// and connection is frequently lost
|
||||||
|
// before receiving status line.
|
||||||
|
//
|
||||||
|
// `from` must be the last addr, see `receive_imf_inner()` why.
|
||||||
if context.get_config_bool(Config::BccSelf).await?
|
if context.get_config_bool(Config::BccSelf).await?
|
||||||
&& context.get_config_delete_server_after().await? != Some(0)
|
|
||||||
&& !recipients
|
&& !recipients
|
||||||
.iter()
|
.iter()
|
||||||
.any(|x| x.to_lowercase() == lowercase_from)
|
.any(|x| x.to_lowercase() == lowercase_from)
|
||||||
|
|||||||
Reference in New Issue
Block a user