diff options
author | Patrick Cloke <clokep@users.noreply.github.com> | 2021-01-27 10:59:50 -0500 |
---|---|---|
committer | GitHub <noreply@github.com> | 2021-01-27 10:59:50 -0500 |
commit | e54746bdf7d5c831eabe4dcea76a7626f1de73df (patch) | |
tree | 262d65e6c945adfa2d64bfe51e70c09d2e1d7d06 /synapse/config/registration.py | |
parent | Add a note to changelog about redis usage (#9227) (diff) | |
download | synapse-e54746bdf7d5c831eabe4dcea76a7626f1de73df.tar.xz |
Clean-up the template loading code. (#9200)
* Enables autoescape by default for HTML files. * Adds a new read_template method for reading a single template. * Some logic clean-up.
Diffstat (limited to 'synapse/config/registration.py')
-rw-r--r-- | synapse/config/registration.py | 4 |
1 files changed, 1 insertions, 3 deletions
diff --git a/synapse/config/registration.py b/synapse/config/registration.py index 4bfc69cb7a..ac48913a0b 100644 --- a/synapse/config/registration.py +++ b/synapse/config/registration.py @@ -176,9 +176,7 @@ class RegistrationConfig(Config): self.session_lifetime = session_lifetime # The success template used during fallback auth. - self.fallback_success_template = self.read_templates( - ["auth_success.html"], autoescape=True - )[0] + self.fallback_success_template = self.read_template("auth_success.html") def generate_config_section(self, generate_secrets=False, **kwargs): if generate_secrets: |