From c2929880318f930cc3358b9a45ad8ea8074652ef Mon Sep 17 00:00:00 2001 From: Niko Ehrenfeuchter <nikolaus.ehrenfeuchter@unibas.ch> Date: Mon, 29 Apr 2019 15:28:32 +0200 Subject: [PATCH] Explain why email is not being sent but printed to the log instead --- ATxService/Email.cs | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/ATxService/Email.cs b/ATxService/Email.cs index 1ed9d56..91fdf61 100644 --- a/ATxService/Email.cs +++ b/ATxService/Email.cs @@ -20,7 +20,8 @@ namespace ATxService subject = $"{_config.EmailPrefix}{ServiceName} - {subject} - {_config.HostAlias}"; body += $"\n\n--\n[{_versionSummary}]\n"; if (string.IsNullOrEmpty(_config.SmtpHost)) { - Log.Debug("SendEmail: {0}\n{1}", subject, body); + Log.Debug("SendEmail: config option <SmtpHost> is unset, not sending mail - " + + "content shown below.\n[Subject] {0}\n[Body] {1}", subject, body); return; } if (!recipient.Contains(@"@")) { -- GitLab