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

Commit e7f7643c authored by Amith Yamasani's avatar Amith Yamasani Committed by Android Git Automerger
Browse files

am 6ef6f183: Stability fixes for Settings. Asynchronous callbacks causing NPEs.

* commit '6ef6f183':
  Stability fixes for Settings. Asynchronous callbacks causing NPEs.
parents c1db1192 6ef6f183
Loading
Loading
Loading
Loading
+2 −0
Original line number Diff line number Diff line
@@ -230,6 +230,7 @@ public class ManageAccountsSettings extends AccountPreferenceBase
    }

    private void setBackgroundDataInt(boolean enabled) {
        if (getActivity() == null) return;
        final ConnectivityManager connManager = (ConnectivityManager)
                getActivity().getSystemService(Context.CONNECTIVITY_SERVICE);
        connManager.setBackgroundDataSetting(enabled);
@@ -315,6 +316,7 @@ public class ManageAccountsSettings extends AccountPreferenceBase

    @Override
    public void onAccountsUpdated(Account[] accounts) {
        if (getActivity() == null) return;
        mManageAccountsCategory.removeAll();
        for (int i = 0, n = accounts.length; i < n; i++) {
            final Account account = accounts[i];