From e794b397d386a778d7d5c4ab25bf0965206434fd Mon Sep 17 00:00:00 2001 From: BlackDex Date: Wed, 3 Feb 2021 23:47:48 +0100 Subject: [PATCH] Fixed small buggy in validation --- src/config.rs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/config.rs b/src/config.rs index 685f8294..3f344f01 100644 --- a/src/config.rs +++ b/src/config.rs @@ -557,7 +557,7 @@ fn validate_config(cfg: &ConfigItems) -> Result<(), Error> { err!("Both `SMTP_HOST` and `SMTP_FROM` need to be set for email support") } - if !cfg.smtp_from.contains('@') { + if cfg.smtp_host.is_some() && !cfg.smtp_from.contains('@') { err!("SMTP_FROM does not contain a mandatory @ sign") }