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

Commit 303c7869 authored by Todd Kennedy's avatar Todd Kennedy
Browse files

Don't require BROWSABLE

Initially we wanted to limit instant apps to VIEW/BROWSABLE
intents, but, apparently apps don't always set the BROWSABLE
category. So, allow any VIEW intent w/ a URL to resovle to
an instant app.

Change-Id: I96e25cca8abcbe89b4a227b707112184c19565c6
Fixes: 38146110
Test: Manual
Test: open go/aia-test-links
Test: click any link
Test: notice it launches the instant app directly [instead of going through the installer]
parent 7cf5f74f
Loading
Loading
Loading
Loading
+0 −1
Original line number Diff line number Diff line
@@ -637,7 +637,6 @@ class ActivityStarter {
        if (componentSpecified
                && intent.getData() != null
                && Intent.ACTION_VIEW.equals(intent.getAction())
                && intent.hasCategory(Intent.CATEGORY_BROWSABLE)
                && mService.getPackageManagerInternalLocked()
                        .isInstantAppInstallerComponent(intent.getComponent())) {
            // intercept intents targeted directly to the ephemeral installer the
+0 −1
Original line number Diff line number Diff line
@@ -4218,7 +4218,6 @@ public class PackageManagerService extends IPackageManager.Stub
            final boolean allowMatchInstant =
                    (includeInstantApps
                            && Intent.ACTION_VIEW.equals(intent.getAction())
                            && intent.hasCategory(Intent.CATEGORY_BROWSABLE)
                            && hasWebURI(intent))
                    || isSpecialProcess
                    || mContext.checkCallingOrSelfPermission(