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

Commit b6e4484d authored by Hall Liu's avatar Hall Liu Committed by android-build-merger
Browse files

Merge "Clear voicemail information if CDMA sim is inserted" into oc-dr1-dev

am: 1306a531

Change-Id: Iec6abded0f1bfd34ab4fe2c50bfcf17a8e91e803
parents 413f617d 1306a531
Loading
Loading
Loading
Loading
+10 −11
Original line number Diff line number Diff line
@@ -2278,18 +2278,17 @@ public class GsmCdmaPhone extends Phone {
                break;

            case EVENT_SIM_RECORDS_LOADED:
                if (isPhoneTypeGsm()) {
                updateCurrentCarrierInProvider();

                // Check if this is a different SIM than the previous one. If so unset the
                // voice mail number.
                String imsi = getVmSimImsi();
                String imsiFromSIM = getSubscriberId();
                    if (imsi != null && imsiFromSIM != null && !imsiFromSIM.equals(imsi)) {
                if ((!isPhoneTypeGsm() || imsi != null) && imsiFromSIM != null
                        && !imsiFromSIM.equals(imsi)) {
                    storeVoiceMailNumber(null);
                    setVmSimImsi(null);
                }
                }

                mSimRecordsLoadedRegistrants.notifyRegistrants();
                break;