mirror of
https://github.com/simple-login/app.git
synced 2025-02-23 23:34:05 +08:00
handle the case where alias is deleted in handle_bounce_reply_phase()
This commit is contained in:
parent
271734f5e2
commit
7e53b97f81
1 changed files with 5 additions and 0 deletions
|
@ -1271,6 +1271,11 @@ def handle_bounce_reply_phase(msg: Message, rcpt_to: str):
|
|||
Happens when an email cannot be sent from an alias to a contact
|
||||
"""
|
||||
alias = Alias.get_by(email=rcpt_to)
|
||||
# the alias has been deleted in the meantime
|
||||
if not alias:
|
||||
LOG.warning("No such alias for %s", rcpt_to)
|
||||
return
|
||||
|
||||
user = alias.user
|
||||
|
||||
try:
|
||||
|
|
Loading…
Reference in a new issue