From ed35302cd15c526e425785daa3b2812cf1b4d2a1 Mon Sep 17 00:00:00 2001 From: Andrew Morgan Date: Tue, 4 Jun 2019 19:09:59 +0100 Subject: [PATCH] Fix validation token lifetime email_ prefix --- synapse/config/emailconfig.py | 2 +- synapse/rest/client/v2_alpha/account.py | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/synapse/config/emailconfig.py b/synapse/config/emailconfig.py index 1134d78290..4f1fa669a6 100644 --- a/synapse/config/emailconfig.py +++ b/synapse/config/emailconfig.py @@ -78,7 +78,7 @@ class EmailConfig(Config): "enable_password_reset_from_is", False, ) - self.validation_token_lifetime = email_config.get( + self.email_validation_token_lifetime = email_config.get( "validation_token_lifetime", 15 * 60, ) diff --git a/synapse/rest/client/v2_alpha/account.py b/synapse/rest/client/v2_alpha/account.py index 2601f99563..60d7d2005f 100644 --- a/synapse/rest/client/v2_alpha/account.py +++ b/synapse/rest/client/v2_alpha/account.py @@ -159,7 +159,7 @@ class EmailPasswordRequestTokenRestServlet(RestServlet): ) token_expires = (self.hs.clock.time_msec() + - self.config.validation_token_lifetime * 1000) + self.config.email_validation_token_lifetime * 1000) yield self.datastore.insert_threepid_validation_token( session_id, token, kwargs.get("next_link"), token_expires,