Introduce utility method SubscripitonManager.canManageSubscriptionAsUser
SubscriptionManager.canManageSubscription always uses the user context created from SubscriptionManager to query packages. It is usually the system user in phone process services. When the carrier app is installed on secondary users (e.g. main user in HSUM) only, the query will fail. The new utility method allows phone process components to query packages as designed user and avoid duplicated logic in services side. Bug: 371452139 Test: FrameworksTelephonyTests Flag: com.android.internal.telephony.flags.hsum_package_manager Change-Id: Icc1376744de356e2bb3dcf2e7bf68d89b97c16ad
Loading
Please register or sign in to comment