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

Commit fc33a423 authored by Holly Jiuyu Sun's avatar Holly Jiuyu Sun
Browse files

Check whether cardId is valid in EuiccManager#isEnabled.

EuiccManager#isEnabled should be only true if its cardId is a valid one.

Bug: 111614811
Test: test on phone
Change-Id: I7b63d3e117a1bd1eb17dab8e1a7b1dfec1a8abe8
parent e3ecbde6
Loading
Loading
Loading
Loading
+1 −1
Original line number Diff line number Diff line
@@ -361,7 +361,7 @@ public class EuiccManager {
    public boolean isEnabled() {
        // In the future, this may reach out to IEuiccController (if non-null) to check any dynamic
        // restrictions.
        return getIEuiccController() != null;
        return getIEuiccController() != null && mCardId != TelephonyManager.INVALID_CARD_ID;
    }

    /**