Add log line when sending a task-related email

This commit is contained in:
sabaimran
2024-05-01 13:56:02 +05:30
parent a86f95117e
commit 28578310d1

View File

@@ -44,7 +44,7 @@ async def send_welcome_email(name, email):
{
"from": "team@khoj.dev",
"to": email,
"subject": f"Welcome to Khoj, {name}!" if name else "Welcome to Khoj!",
"subject": f"{name}, four ways to use Khoj!" if name else "Four ways to use Khoj!",
"html": html_content,
}
)
@@ -55,6 +55,8 @@ def send_task_email(name, email, query, result, subject):
logger.debug("Email sending disabled")
return
logger.info(f"Sending email to {email} for task {subject}")
template = env.get_template("task.html")
html_result = markdown_it.MarkdownIt().render(result)