You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@allura.apache.org by di...@apache.org on 2022/09/07 14:41:41 UTC

[allura] branch dw/8460 updated: fixup! [#8460] add new email @task which sends an already formatted email content

This is an automated email from the ASF dual-hosted git repository.

dill0wn pushed a commit to branch dw/8460
in repository https://gitbox.apache.org/repos/asf/allura.git


The following commit(s) were added to refs/heads/dw/8460 by this push:
     new aa794076c fixup! [#8460] add new email @task which sends an already formatted email content
aa794076c is described below

commit aa794076ca8e3a0f9c960352992d61a5491b9172
Author: Dillon Walls <di...@slashdotmedia.com>
AuthorDate: Wed Sep 7 14:41:34 2022 +0000

    fixup! [#8460] add new email @task which sends an already formatted email content
---
 Allura/allura/tasks/mail_tasks.py | 5 +++--
 1 file changed, 3 insertions(+), 2 deletions(-)

diff --git a/Allura/allura/tasks/mail_tasks.py b/Allura/allura/tasks/mail_tasks.py
index dda48888e..0a8de3f8c 100644
--- a/Allura/allura/tasks/mail_tasks.py
+++ b/Allura/allura/tasks/mail_tasks.py
@@ -248,9 +248,10 @@ def sendsimplemail(
 
 @task
 def send_raw_content(mail_system, addr_from, addr_to, full_email_content):
-    log.info("send_raw_content {} from: {} to: {}".format(mail_system, addr_from, addr_to))
     if mail_system == 'local':
-        smtp_client.send(addr_from, [addr_to], full_email_content)
+        if isinstance(addr_to, str):
+            addr_to = [addr_to]
+        smtp_client.send(addr_from, addr_to, full_email_content)
 
 
 def send_system_mail_to_user(user_or_emailaddr, subject, text):