We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 5e3d3ee commit ad22590Copy full SHA for ad22590
server/controllers/emails.py
@@ -371,8 +371,10 @@ def send_email():
371
).scalar()
372
if not thread:
373
return {"message": "Thread not found"}, 400
374
+
375
+ breaked_line_text = data["body"].replace("<br/>", "\n") # replace <br /> with \n in body
376
clean_regex = re.compile("<.*?>")
- clean_text = re.sub(clean_regex, " ", data["body"])
377
+ clean_text = re.sub(clean_regex, " ", breaked_line_text)
378
context = {"body": data["body"]}
379
template = env.get_template("template.html")
380
body = template.render(**context)
0 commit comments