mirror of
https://github.com/stalwartlabs/mail-server.git
synced 2025-09-13 23:44:40 +08:00
Skip card-is-ham override when sender address == recipient address (#1648)
This commit is contained in:
parent
227d47a1c3
commit
9c9f216294
1 changed files with 12 additions and 11 deletions
|
@ -204,17 +204,18 @@ impl EmailIngest for Server {
|
||||||
.and_then(|s| s.address())
|
.and_then(|s| s.address())
|
||||||
.and_then(sanitize_email)
|
.and_then(sanitize_email)
|
||||||
{
|
{
|
||||||
if !self
|
if sender != deliver_to
|
||||||
.store()
|
&& !self
|
||||||
.filter(
|
.store()
|
||||||
account_id,
|
.filter(
|
||||||
Collection::ContactCard,
|
account_id,
|
||||||
vec![Filter::eq(IDX_EMAIL, sender.into_bytes())],
|
Collection::ContactCard,
|
||||||
)
|
vec![Filter::eq(IDX_EMAIL, sender.into_bytes())],
|
||||||
.await
|
)
|
||||||
.caused_by(trc::location!())?
|
.await
|
||||||
.results
|
.caused_by(trc::location!())?
|
||||||
.is_empty()
|
.results
|
||||||
|
.is_empty()
|
||||||
{
|
{
|
||||||
is_spam = false;
|
is_spam = false;
|
||||||
if self
|
if self
|
||||||
|
|
Loading…
Add table
Reference in a new issue