diff --git a/src/smtp.rs b/src/smtp.rs index 405f4f5e0..100b567c2 100644 --- a/src/smtp.rs +++ b/src/smtp.rs @@ -414,7 +414,11 @@ pub(crate) async fn send_msg_to_smtp( .await?; } SendResult::Failure(ref err) => { - if err.to_string().contains("Invalid unencrypted mail") { + if err + .to_string() + .to_lowercase() + .contains("invalid unencrypted mail") + { let res = context .sql .query_row_optional(