From 9d641d88b785dd4b4e6e7dca3356678a42a3ac23 Mon Sep 17 00:00:00 2001 From: Cyberes <64224601+Cyberes@users.noreply.github.com> Date: Thu, 30 Mar 2023 04:44:53 -0600 Subject: [PATCH] Fix missing app variable in mail subject for password resets (#15352) * Update mailer.py Fix `KeyError: 'app'` * Create 15352.bugfix Signed-off-by: Cyberes --------- Signed-off-by: Cyberes --- changelog.d/15352.bugfix | 1 + synapse/push/mailer.py | 2 +- 2 files changed, 2 insertions(+), 1 deletion(-) create mode 100644 changelog.d/15352.bugfix diff --git a/changelog.d/15352.bugfix b/changelog.d/15352.bugfix new file mode 100644 index 0000000000..36d6615cac --- /dev/null +++ b/changelog.d/15352.bugfix @@ -0,0 +1 @@ +Fix missing app variable in mail subject for password resets. Contributed by Cyberes. diff --git a/synapse/push/mailer.py b/synapse/push/mailer.py index 93b255ced5..491a09b71d 100644 --- a/synapse/push/mailer.py +++ b/synapse/push/mailer.py @@ -149,7 +149,7 @@ class Mailer: await self.send_email( email_address, self.email_subjects.password_reset - % {"server_name": self.hs.config.server.server_name}, + % {"server_name": self.hs.config.server.server_name, "app": self.app_name}, template_vars, )