mirror of
https://github.com/discourse/discourse.git
synced 2025-05-24 03:36:18 +08:00
FIX: don't error out when we receive a bounce associated to a deleted user
This commit is contained in:
@ -133,6 +133,8 @@ class WebhooksController < ActionController::Base
|
|||||||
return if email_log.nil?
|
return if email_log.nil?
|
||||||
|
|
||||||
email_log.update_columns(bounced: true)
|
email_log.update_columns(bounced: true)
|
||||||
|
return if email_log.user.nil? || email_log.user.email.blank?
|
||||||
|
|
||||||
Email::Receiver.update_bounce_score(email_log.user.email, bounce_score)
|
Email::Receiver.update_bounce_score(email_log.user.email, bounce_score)
|
||||||
end
|
end
|
||||||
|
|
||||||
|
Reference in New Issue
Block a user