Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 66235f93 authored by Mohammed Althaf T's avatar Mohammed Althaf T 😊 Committed by Nishith Khanna
Browse files

setup: Fix IllegalStateException on finish

parent 47baeca7
Loading
Loading
Loading
Loading
+4 −1
Original line number Diff line number Diff line
@@ -257,8 +257,11 @@ public abstract class BaseSetupWizardActivity extends AppCompatActivity implemen
        }
        setResult(resultCode, data);
        Intent intent = WizardManagerHelper.getNextIntent(getIntent(), resultCode, data);
        // Ensure the ActivityResultLauncher is registered before using it
        if (mNextIntentResultLauncher != null) {
            mNextIntentResultLauncher.launch(intent);
        }
    }

    /** Adorn the Intent with Setup Wizard-related extras. */
    protected Intent decorateIntent(Intent intent) {
+4 −1
Original line number Diff line number Diff line
@@ -73,7 +73,10 @@ public abstract class SubBaseActivity extends BaseSetupWizardActivity {
            subactivityIntent.putExtra(EXTRA_WIZARD_BUNDLE, wizardBundle);
        }
        try {
            // Ensure the ActivityResultLauncher is registered before using it
            if (mSubactivityResultLauncher != null) {
                mSubactivityResultLauncher.launch(subactivityIntent);
            }
        } catch (ActivityNotFoundException e) {
            Log.w(TAG, "activity not found; start next screen and finish; intent=" + intent);
            mIsSubactivityNotFound = true;