diff --git a/app/lib/email_processor.rb b/app/lib/email_processor.rb index 137c0ee1..871930e5 100644 --- a/app/lib/email_processor.rb +++ b/app/lib/email_processor.rb @@ -332,8 +332,11 @@ def clean_html_version(html) html = html.split('
').first # strip out gmail signature html = ActionController::Base.helpers.sanitize(html, tags: %w(strong em a div span ul ol li b i br p hr u em blockquote), attributes: %w(href target)) html = html.split("
--
").first # strip out gmail signature + html = html.presence || "" html = html.split("

\n
--
").first # strip out gmail signature + html = html.presence || "" html = html.split("
--").first # strip out gmail signature + html = html.presence || "" html = html.split("
\n--").first # strip out gmail signature html&.gsub!(/\A/, "") # remove
from very beginning of html html&.gsub!(/
.+<\/div>/, "") # remove hidden divs / tracking pixels