From af948eb35dcc4b933ebb2a0ddd2658aab4177295 Mon Sep 17 00:00:00 2001 From: ggurdin Date: Mon, 2 Feb 2026 12:21:17 -0500 Subject: [PATCH] fix login redirect --- lib/widgets/matrix.dart | 10 ++++++++-- 1 file changed, 8 insertions(+), 2 deletions(-) diff --git a/lib/widgets/matrix.dart b/lib/widgets/matrix.dart index 2564833e2..063c3da30 100644 --- a/lib/widgets/matrix.dart +++ b/lib/widgets/matrix.dart @@ -199,7 +199,7 @@ class MatrixState extends State with WidgetsBindingObserver { .stream .where((l) => l == LoginState.loggedIn) .first - .then((_) { + .then((_) async { // #Pangea MatrixState.pangeaController.handleLoginStateChange( LoginState.loggedIn, @@ -216,7 +216,13 @@ class MatrixState extends State with WidgetsBindingObserver { ); _registerSubs(_loginClientCandidate!.clientName); _loginClientCandidate = null; - FluffyChatApp.router.go('/rooms'); + // #Pangea + // FluffyChatApp.router.go('/rooms'); + final isL2Set = await pangeaController.userController.isUserL2Set; + FluffyChatApp.router.go( + isL2Set ? '/rooms' : '/registration/create', + ); + // Pangea# }); // #Pangea candidate.homeserver = Uri.parse("https://${AppConfig.defaultHomeserver}");