Skip to content

Commit

Permalink
Closes mozilla-mobile#6003: MigrationProgressActivity: Always open br…
Browse files Browse the repository at this point in the history
…owser.
  • Loading branch information
pocmo committed Feb 25, 2020
1 parent 0434e53 commit 5dd6caf
Showing 1 changed file with 6 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@

package org.mozilla.fenix.migration

import android.content.Intent
import android.os.Bundle
import android.view.LayoutInflater
import android.view.View
Expand Down Expand Up @@ -64,11 +65,15 @@ class MigrationProgressActivity : AbstractMigrationProgressActivity() {
finish()
overridePendingTransition(0, 0)

store.dispatch(MigrationAction.Clear)

// If we received a user-initiated intent, throw this back to the intent receiver.
if (intent.hasExtra(HomeActivity.OPEN_TO_BROWSER)) {
store.dispatch(MigrationAction.Clear)
intent.setClassName(applicationContext, IntentReceiverActivity::class.java.name)
startActivity(intent)
} else {
// Fallback: Just launch the browser
startActivity(Intent(this@MigrationProgressActivity, HomeActivity::class.java))
}
}
text = getString(R.string.migration_updating_app_button_text, appName)
Expand Down

0 comments on commit 5dd6caf

Please sign in to comment.