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

Commit beb3d8b1 authored by Brian Muramatsu's avatar Brian Muramatsu Committed by Android (Google) Code Review
Browse files

Merge "Fix Settings NPE" into jb-dev

parents 3cc385b8 c28af52e
Loading
Loading
Loading
Loading
+5 −1
Original line number Diff line number Diff line
@@ -439,6 +439,10 @@ public class Settings extends PreferenceActivity
        List<Header> accountHeaders = new ArrayList<Header>(accountTypes.length);
        for (String accountType : accountTypes) {
            CharSequence label = mAuthenticatorHelper.getLabelForType(this, accountType);
            if (label == null) {
                continue;
            }

            Account[] accounts = AccountManager.get(this).getAccountsByType(accountType);
            boolean skipToAccount = accounts.length == 1
                    && !mAuthenticatorHelper.hasAccountPreferences(accountType);