Default value for public_baseurl (#11210)

We might as well use a default value for `public_baseurl` based on
`server_name` - in many cases, it will be correct.
This commit is contained in:
Richard van der Hoff 2021-11-08 14:13:10 +00:00 committed by GitHub
parent 556a488209
commit 86a497efaa
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
16 changed files with 62 additions and 73 deletions

View file

@ -38,9 +38,6 @@ class ConsentURIBuilder:
def __init__(self, hs_config: HomeServerConfig):
if hs_config.key.form_secret is None:
raise ConfigError("form_secret not set in config")
if hs_config.server.public_baseurl is None:
raise ConfigError("public_baseurl not set in config")
self._hmac_secret = hs_config.key.form_secret.encode("utf-8")
self._public_baseurl = hs_config.server.public_baseurl