diff options
author | Amber Brown <hawkowl@atleastfornow.net> | 2019-10-10 09:39:35 +0100 |
---|---|---|
committer | GitHub <noreply@github.com> | 2019-10-10 09:39:35 +0100 |
commit | f743108a94658eb1dbaf168d39874272f756a386 (patch) | |
tree | b9f745e72ae01b13adc9b273884fd31c8fe4f355 /synapse/config/registration.py | |
parent | Merge pull request #6185 from matrix-org/erikj/fix_censored_evnets (diff) | |
download | synapse-f743108a94658eb1dbaf168d39874272f756a386.tar.xz |
Refactor HomeserverConfig so it can be typechecked (#6137)
Diffstat (limited to 'synapse/config/registration.py')
-rw-r--r-- | synapse/config/registration.py | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/synapse/config/registration.py b/synapse/config/registration.py index bef89e2bf4..b3e3e6dda2 100644 --- a/synapse/config/registration.py +++ b/synapse/config/registration.py @@ -24,6 +24,8 @@ from synapse.util.stringutils import random_string_with_symbols class AccountValidityConfig(Config): + section = "accountvalidity" + def __init__(self, config, synapse_config): self.enabled = config.get("enabled", False) self.renew_by_email_enabled = "renew_at" in config @@ -77,6 +79,8 @@ class AccountValidityConfig(Config): class RegistrationConfig(Config): + section = "registration" + def read_config(self, config, **kwargs): self.enable_registration = bool( strtobool(str(config.get("enable_registration", False))) |