Ensure we only send ReceiveFirstIntent once (#701)

This commit is contained in:
Brian Yencho 2024-01-21 11:35:39 -06:00 committed by Álison Fernandes
parent ffba00bf83
commit 99f5325580

View file

@ -32,11 +32,13 @@ class MainActivity : AppCompatActivity() {
installSplashScreen().setKeepOnScreenCondition { shouldShowSplashScreen }
super.onCreate(savedInstanceState)
mainViewModel.trySendAction(
MainAction.ReceiveFirstIntent(
intent = intent,
),
)
if (savedInstanceState == null) {
mainViewModel.trySendAction(
MainAction.ReceiveFirstIntent(
intent = intent,
),
)
}
// Within the app the language will change dynamically and will be managed
// by the OS, but we need to ensure we properly set the language when