forked from mystiq/hydrogen-web
Return token stage from createRegistrationStage
This commit is contained in:
parent
c40801efd9
commit
ed151c8567
1 changed files with 3 additions and 0 deletions
|
@ -18,6 +18,7 @@ import type {HomeServerApi} from "../net/HomeServerApi";
|
|||
import type {BaseRegistrationStage} from "./stages/BaseRegistrationStage";
|
||||
import {DummyAuth} from "./stages/DummyAuth";
|
||||
import {TermsAuth} from "./stages/TermsAuth";
|
||||
import {TokenAuth, TOKEN_AUTH_TYPE} from "./stages/TokenAuth";
|
||||
import type {
|
||||
AccountDetails,
|
||||
RegistrationFlow,
|
||||
|
@ -108,6 +109,8 @@ export class Registration {
|
|||
return new DummyAuth(session, params?.[type]);
|
||||
case "m.login.terms":
|
||||
return new TermsAuth(session, params?.[type]);
|
||||
case TOKEN_AUTH_TYPE:
|
||||
return new TokenAuth(session, params?.[type]);
|
||||
default:
|
||||
throw new Error(`Unknown stage: ${type}`);
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue