Handle cases of no default server
This commit is contained in:
parent
45caa8baab
commit
bf97fd67b4
2 changed files with 4 additions and 2 deletions
|
@ -452,8 +452,6 @@ async function verifyServerConfig() {
|
|||
// TODO: TravisR - Handle query string arguments for hs_url and is_url
|
||||
// We probably don't want to handle them unless the user is logged out though?
|
||||
|
||||
// TODO: TravisR - Handle case of no options specified whatsoever
|
||||
|
||||
const config = SdkConfig.get();
|
||||
let wkConfig = config['default_server_config']; // overwritten later under some conditions
|
||||
const serverName = config['default_server_name'];
|
||||
|
@ -467,6 +465,9 @@ async function verifyServerConfig() {
|
|||
"or default_hs_url.",
|
||||
));
|
||||
}
|
||||
if (incompatibleOptions.length < 1) {
|
||||
throw newTranslatableError(_td("Invalid configuration: no default server specified."));
|
||||
}
|
||||
|
||||
if (hsUrl) {
|
||||
console.log("Config uses a default_hs_url - constructing a default_server_config using this information");
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue