Skip to content
Snippets Groups Projects
Commit f1056023 authored by RMidhunSuresh's avatar RMidhunSuresh
Browse files

Don't die if terms login stage is not found

parent f6daffe2
No related branches found
No related tags found
No related merge requests found
...@@ -31,7 +31,9 @@ export class AccountSetupViewModel extends ViewModel { ...@@ -31,7 +31,9 @@ export class AccountSetupViewModel extends ViewModel {
while (stage.type !== "m.login.terms") { while (stage.type !== "m.login.terms") {
stage = stage.nextStage; stage = stage.nextStage;
if (!stage) { if (!stage) {
throw new Error("Terms login stage not found"); // If terms login stage is not found, go straight to completeRegistration()
this.completeRegistration();
return;
} }
} }
this._privacyPolicyLink = stage.privacyPolicy.en?.url; this._privacyPolicyLink = stage.privacyPolicy.en?.url;
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment