def __init__(self, hs: "HomeServer"): super().__init__() self._sso_handler = hs.get_sso_handler() def template_search_dirs(): if hs.config.sso.sso_template_dir: yield hs.config.sso.sso_template_dir yield hs.config.sso.default_template_dir self._jinja_env = build_jinja_env(template_search_dirs(), hs.config)
def __init__(self, hs: "HomeServer"): super().__init__() self._sso_handler = hs.get_sso_handler() self._server_name = hs.hostname self._consent_version = hs.config.consent.user_consent_version def template_search_dirs(): if hs.config.sso.sso_template_dir: yield hs.config.sso.sso_template_dir yield hs.config.sso.default_template_dir self._jinja_env = build_jinja_env(template_search_dirs(), hs.config)
def __init__(self, hs: "HomeServer"): super().__init__() self._sso_handler = hs.get_sso_handler() def template_search_dirs() -> Generator[str, None, None]: if hs.config.server.custom_template_directory: yield hs.config.server.custom_template_directory if hs.config.sso.sso_template_dir: yield hs.config.sso.sso_template_dir yield hs.config.sso.default_template_dir self._jinja_env = build_jinja_env(list(template_search_dirs()), hs.config)