From 7b1f9281162fef330a9607c1d3fa3ac3078d1d21 Mon Sep 17 00:00:00 2001 From: "kshitij.sobti" Date: Mon, 2 Dec 2024 18:16:18 +0530 Subject: [PATCH] fixup! feat: Support for login and registration via a browser custom tab --- app/src/main/java/org/openedx/app/AppActivity.kt | 8 +++----- 1 file changed, 3 insertions(+), 5 deletions(-) diff --git a/app/src/main/java/org/openedx/app/AppActivity.kt b/app/src/main/java/org/openedx/app/AppActivity.kt index f74bc8af2..19c096338 100644 --- a/app/src/main/java/org/openedx/app/AppActivity.kt +++ b/app/src/main/java/org/openedx/app/AppActivity.kt @@ -168,12 +168,10 @@ class AppActivity : AppCompatActivity(), InsetHolder, WindowSizeHolder { if (savedInstanceState == null) { when { corePreferencesManager.user == null -> { - val authCode = authCode; - - if (viewModel.isLogistrationEnabled && authCode == null) { - addFragment(LogistrationFragment()) + val fragment = if (viewModel.isLogistrationEnabled && authCode == null) { + LogistrationFragment() } else { - addFragment(SignInFragment.newInstance(null, null, authCode = authCode)) + SignInFragment.newInstance(null, null, authCode = authCode) } addFragment(fragment) }