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

Commit 99c0f3fe authored by Bonian Chen's avatar Bonian Chen
Browse files

[Settings] Refactor MmsMessagePreferenceController

Refactor MmsMessagePreferenceController

Bug: 150352656
Test: make
Change-Id: Id72f8f95eb12bb5c8f060df6c247312c56f2e69a
parent 291ff22d
Loading
Loading
Loading
Loading
+2 −2
Original line number Diff line number Diff line
@@ -50,8 +50,8 @@ public class MmsMessagePreferenceController extends TelephonyTogglePreferenceCon

    @Override
    public int getAvailabilityStatus(int subId) {
        final TelephonyManager telephonyManager = TelephonyManager
                .from(mContext).createForSubscriptionId(subId);
        final TelephonyManager telephonyManager = mContext.getSystemService(TelephonyManager.class)
                .createForSubscriptionId(subId);
        return (subId != SubscriptionManager.INVALID_SUBSCRIPTION_ID
                && !telephonyManager.isDataEnabled()
                && telephonyManager.isApnMetered(ApnSetting.TYPE_MMS))