chore: Use the name of the sender from the mail object

if the sender email is Sony Mathew <Sony@chatwoot.com> Contact should be built with Sony Mathew

Fixes #2911
This commit is contained in:
Tejaswini Chile
2021-09-16 13:26:52 +05:30
committed by GitHub
parent 799e0ed4f5
commit a0ffefad71
4 changed files with 653 additions and 1 deletions

View File

@@ -82,6 +82,6 @@ class SupportMailbox < ApplicationMailbox
end
def identify_contact_name
processed_mail.from.first.split('@').first
processed_mail.sender_name || processed_mail.from.first.split('@').first
end
end