Parse multipart/related parts recursively (#808)

This is to ensure that tracking pixels are correctly added to all nested parts of the email.
This commit is contained in:
Oliver Kuldmäe
2019-11-22 17:33:50 +00:00
committed by Adam Cooke
parent dcb2919cc6
commit 2d9a18f658
+1 -1
View File
@@ -71,7 +71,7 @@ module Postal
part.body = parse(part.body.decoded.dup, :text)
part.content_transfer_encoding = nil
part.charset = 'UTF-8'
elsif part.content_type =~ /multipart\/alternative/
elsif part.content_type =~ /multipart\/(alternative|related)/
unless part.parts.empty?
parse_parts(part.parts)
end