Skip to content

Commit f0fa841

Browse files
Jean-Baptiste QueruAndroid Code Review
authored andcommitted
Merge "Make hasIccCard return true if RUIM card is present."
2 parents ce3ac5f + 213c853 commit f0fa841

File tree

1 file changed

+4
-5
lines changed

1 file changed

+4
-5
lines changed

telephony/java/com/android/internal/telephony/IccCard.java

Lines changed: 4 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -672,12 +672,11 @@ public boolean isApplicationOnIcc(IccCardApplication.AppType type) {
672672
* @return true if a ICC card is present
673673
*/
674674
public boolean hasIccCard() {
675-
boolean isIccPresent;
676-
if (mPhone.getPhoneName().equals("GSM")) {
677-
return mIccCardStatus.getCardState().isCardPresent();
678-
} else {
679-
// TODO: Make work with a CDMA device with a RUIM card.
675+
if (mIccCardStatus == null) {
680676
return false;
677+
} else {
678+
// Returns ICC card status for both GSM and CDMA mode
679+
return mIccCardStatus.getCardState().isCardPresent();
681680
}
682681
}
683682

0 commit comments

Comments
 (0)