mirror of
https://github.com/discourse/discourse.git
synced 2025-01-31 17:29:47 +08:00
FIX: don't create staged user(s) when receiving a bounce (mailer-deamon begone)
This commit is contained in:
parent
829143bf88
commit
7d0dc7cb7a
|
@ -62,6 +62,7 @@ module Email
|
||||||
end
|
end
|
||||||
|
|
||||||
def process_internal
|
def process_internal
|
||||||
|
raise BouncedEmailError if is_bounce?
|
||||||
raise ScreenedEmailError if ScreenedEmail.should_block?(@from_email)
|
raise ScreenedEmailError if ScreenedEmail.should_block?(@from_email)
|
||||||
|
|
||||||
user = find_or_create_user(@from_email, @from_display_name)
|
user = find_or_create_user(@from_email, @from_display_name)
|
||||||
|
@ -70,7 +71,6 @@ module Email
|
||||||
|
|
||||||
@incoming_email.update_columns(user_id: user.id)
|
@incoming_email.update_columns(user_id: user.id)
|
||||||
|
|
||||||
raise BouncedEmailError if is_bounce?
|
|
||||||
raise InactiveUserError if !user.active && !user.staged
|
raise InactiveUserError if !user.active && !user.staged
|
||||||
raise BlockedUserError if user.blocked
|
raise BlockedUserError if user.blocked
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue
Block a user