Commit 1ed185d4 authored by Sparky93's avatar Sparky93 Committed by Sebastian Kaspari
Browse files

Fix for #7980 - MigrationStore's COMPLETE action now redirects to MigrationProgressActivity

In order to ensure that the user's migration screen is not being bypassed by mistake, we handle the
migration's store COMPLETED state the same way we handle the MIGRATING state.

We can do this because we can treat the initial state (NONE) as being either a fresh start of the
app, either the user's intention of starting the home activity.

Before this change, if the app was being open from the shortcut after the migration was complete,
the user would have been encountered the home activity instead of the migration one.
parent 70556765
......@@ -22,6 +22,7 @@ import
import org.mozilla.fenix.HomeActivity
......@@ -62,6 +63,7 @@ class MigrationProgressActivity : AbstractMigrationProgressActivity() {
// If we received a user-initiated intent, throw this back to the intent receiver.
if (intent.hasExtra(HomeActivity.OPEN_TO_BROWSER)) {
......@@ -24,8 +24,8 @@ class MigrationDecisionActivity : Activity() {
val intent = if (intent != null) intent else Intent()
val activity = when (store.state.progress) {
MigrationProgress.COMPLETED, MigrationProgress.NONE ->
MigrationProgress.MIGRATING ->
MigrationProgress.NONE ->
MigrationProgress.MIGRATING, MigrationProgress.COMPLETED ->
intent.setClass(applicationContext, activity)
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment