This repository was archived by the owner on Apr 26, 2024. It is now read-only.
File tree Expand file tree Collapse file tree 2 files changed +9
-1
lines changed
Expand file tree Collapse file tree 2 files changed +9
-1
lines changed Original file line number Diff line number Diff line change 1+ Deprecate support for `webclient` listeners and non-HTTP(S) `web_client_location` configuration.
Original file line number Diff line number Diff line change @@ -131,11 +131,18 @@ def _listener_http(
131131 resources .update (self ._module_web_resources )
132132 self ._module_web_resources_consumed = True
133133
134- # try to find something useful to redirect '/' to
134+ # Try to find something useful to serve at '/':
135+ #
136+ # 1. Redirect to the web client if it is an HTTP(S) URL.
137+ # 2. Redirect to the web client served via Synapse.
138+ # 3. Redirect to the static "Synapse is running" page.
139+ # 4. Do not redirect and use a blank resource.
135140 if self .config .server .web_client_location_is_redirect :
136141 root_resource : Resource = RootOptionsRedirectResource (
137142 self .config .server .web_client_location
138143 )
144+ elif WEB_CLIENT_PREFIX in resources :
145+ root_resource = RootOptionsRedirectResource (WEB_CLIENT_PREFIX )
139146 elif STATIC_PREFIX in resources :
140147 root_resource = RootOptionsRedirectResource (STATIC_PREFIX )
141148 else :
You can’t perform that action at this time.
0 commit comments