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

Commit 634c1080 authored by Treehugger Robot's avatar Treehugger Robot Committed by Gerrit Code Review
Browse files

Merge "Returns null not empty string if MEID is not available"

parents 5cd5e277 66de2824
Loading
Loading
Loading
Loading
+6 −1
Original line number Original line Diff line number Diff line
@@ -1887,7 +1887,12 @@ public class TelephonyManager {
        if (telephony == null) return null;
        if (telephony == null) return null;


        try {
        try {
            return telephony.getMeidForSlot(slotIndex, getOpPackageName());
            String meid = telephony.getMeidForSlot(slotIndex, getOpPackageName());
            if (TextUtils.isEmpty(meid)) {
                Log.d(TAG, "getMeid: return null because MEID is not available");
                return null;
            }
            return meid;
        } catch (RemoteException ex) {
        } catch (RemoteException ex) {
            return null;
            return null;
        } catch (NullPointerException ex) {
        } catch (NullPointerException ex) {