Skip to content

Commit

Permalink
strip lineBreakAtBeginningOfSignature
Browse files Browse the repository at this point in the history
  • Loading branch information
parterburn committed Jan 8, 2024
1 parent f734cc7 commit 2714847
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions app/lib/email_processor.rb
Original file line number Diff line number Diff line change
Expand Up @@ -347,6 +347,7 @@ def clean_html_version(html)
html = html.split("<br>--").first # strip out gmail signature
html = html.split("<br>\n--").first # strip out gmail signature
html = html.split("<br id=\"lineBreakAtBeginningOfSignature\">").first # strip out gmail signature
html = html.split('<br id=\"lineBreakAtBeginningOfSignature\">').first # strip out gmail signature
html&.gsub!(/\A<br\s*\/?>/, "") # remove <br> from very beginning of html
html&.gsub!(/<div style="display:none;border:0px;width:0px;height:0px;overflow:hidden;">.+<\/div>/, "") # remove hidden divs / tracking pixels
html&.gsub!(/src=\"cid\:\S+\"/, "src=\"\" style=\"display: none;\"") # remove attached images showing as broken inline images
Expand Down

0 comments on commit 2714847

Please sign in to comment.