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

Commit 8325c21f authored by Joonhun Shin's avatar Joonhun Shin Committed by Android (Google) Code Review
Browse files

Merge "Change the time of function call to clear IMS phone number" into main

parents 7e557f72 848a8e44
Loading
Loading
Loading
Loading
+10 −6
Original line number Diff line number Diff line
@@ -1452,6 +1452,11 @@ public class SubscriptionManagerService extends ISub.Stub {
            if (mSlotIndexToSubId.containsKey(phoneId)) {
                markSubscriptionsInactive(phoneId);
            }

            if (Flags.clearCachedImsPhoneNumberWhenDeviceLostImsRegistration()) {
                // Clear the cached Ims phone number
                setNumberFromIms(getSubId(phoneId), new String(""));
            }
        } else if (simState == TelephonyManager.SIM_STATE_NOT_READY) {
            // Check if this is the final state. Only update the subscription if NOT_READY is a
            // final state.
@@ -1464,6 +1469,11 @@ public class SubscriptionManagerService extends ISub.Stub {
            } else {
                logl("updateSubscription: UICC app disabled on slot " + phoneId);
                markSubscriptionsInactive(phoneId);

                if (Flags.clearCachedImsPhoneNumberWhenDeviceLostImsRegistration()) {
                    // Clear the cached Ims phone number
                    setNumberFromIms(getSubId(phoneId), new String(""));
                }
            }
        } else {
            String iccId = getIccId(phoneId);
@@ -1572,12 +1582,6 @@ public class SubscriptionManagerService extends ISub.Stub {
                        loge("updateSubscription: ICC card is not available.");
                    }

                    if (Flags.clearCachedImsPhoneNumberWhenDeviceLostImsRegistration()) {
                        // Clear the cached Ims phone number
                        // before proceeding with Ims Registration
                        setNumberFromIms(subId, new String(""));
                    }

                    // Attempt to restore SIM specific settings when SIM is loaded.
                    Bundle result = mContext.getContentResolver().call(
                            SubscriptionManager.SIM_INFO_BACKUP_AND_RESTORE_CONTENT_URI,