From a055220f5091074cc349d265c85879cecd001cf0 Mon Sep 17 00:00:00 2001 From: Giovanni Barillari Date: Mon, 8 Jul 2024 01:42:01 +0200 Subject: [PATCH] Always convert auth mails' subjects to str --- emmett/tools/auth/ext.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/emmett/tools/auth/ext.py b/emmett/tools/auth/ext.py index 70d89bec..4477af19 100644 --- a/emmett/tools/auth/ext.py +++ b/emmett/tools/auth/ext.py @@ -355,14 +355,14 @@ def _registration_email(self, user, data): data['email'] = user.email return self.app.ext.MailExtension.send_mail( recipients=user.email, - subject=self.config.messages['registration_email_subject'], + subject=str(self.config.messages['registration_email_subject']), body=str(self.config.messages['registration_email_text'] % data)) def _reset_password_email(self, user, data): data['email'] = user.email return self.app.ext.MailExtension.send_mail( recipients=user.email, - subject=self.config.messages['reset_password_email_subject'], + subject=str(self.config.messages['reset_password_email_subject']), body=str(self.config.messages['reset_password_email_text'] % data))