Mercurial > prosody-modules
diff mod_email/mod_email.lua @ 3836:070faeaf51bc
mod_email: Allow sender to override content-type
author | Matthew Wild <mwild1@gmail.com> |
---|---|
date | Sun, 05 Jan 2020 10:48:23 +0000 |
parents | 74d7e59b3511 |
children |
line wrap: on
line diff
--- a/mod_email/mod_email.lua Sat Jan 04 19:48:35 2020 +0100 +++ b/mod_email/mod_email.lua Sun Jan 05 10:48:23 2020 +0000 @@ -14,7 +14,9 @@ }; end headers.To = to; - headers["Content-Type"] = 'text/plain; charset="utf-8"'; + if not headers["Content-Type"] then + headers["Content-Type"] = 'text/plain; charset="utf-8"'; + end local message = smtp.message{ headers = headers; body = content;