fix optional config section related

split api/client well_known

simplify well_known config access

Signed-off-by: Jason Volk <jason@zemos.net>
This commit is contained in:
Jason Volk 2024-11-24 00:19:55 +00:00
parent 5f1cab6850
commit f30b08f015
9 changed files with 144 additions and 138 deletions

View file

@ -198,8 +198,10 @@ pub(crate) async fn login_route(
// send client well-known if specified so the client knows to reconfigure itself
let client_discovery_info: Option<DiscoveryInfo> = services
.globals
.well_known_client()
.server
.config
.well_known
.client
.as_ref()
.map(|server| DiscoveryInfo::new(HomeserverInfo::new(server.to_string())));