class WcoEmail::Message

def part_html_sanitized

def part_html_sanitized
  doc = Nokogiri::HTML part_html
  images = doc.search('img')
  images.each do |img|
    img['src'] = 'missing'
  end
  doc.search('script').remove
  doc.search('meta').remove
  # doc.xpath('//@style').remove
  doc.to_s.gsub('http', '').gsub('href="s://', 'href="https://')
end