Don’t try to mutate the raw_source mail part
Don’t try to mutate the raw_source mail part

mail 2.6 and up uses string literals in Ruby 2.3 and up, and raw_source
is a frozen string. Also according to the mail authors, mutating
raw_source is pretty error-prone, and not an ideal way to achieve the
token substitution.

Instead we should firstly ensure we’re only gsubbing the html/plain
parts of the email, and secondly re-assign rather than mutate the body
parts.
ankane/mailkick,ankane/mailkick