Merge pull request #266 from sc2bigjoe/patch-1

Update smtp.js
This commit is contained in:
Gareth Jones 2015-01-10 15:23:28 +11:00
commit a4be20f8e1

View File

@ -34,9 +34,15 @@ function smtpAppender(config, layout) {
var msg = {
to: config.recipients,
subject: config.subject || subjectLayout(firstEvent),
text: body,
headers: { "Hostname": os.hostname() }
};
if (!config.html) {
msg.text = body;
} else {
msg.html = body;
}
if (config.sender) {
msg.from = config.sender;
}