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

Commit 03256001 authored by Nicholas Sauer's avatar Nicholas Sauer
Browse files

Check for null results from getTypeForAccount.

bug: 63816624
Test: make Contacts and install. No crash.

Change-Id: Ic4f00413d196ff783d033740e0efb1c82c10e361
(cherry picked from commit d9ecda94)
parent 6148c31a
Loading
Loading
Loading
Loading
+4 −3
Original line number Diff line number Diff line
@@ -622,10 +622,11 @@ class AccountTypeManagerImpl extends AccountTypeManager
            final AccountWithDataSet accountWithDataSet = new AccountWithDataSet(
                    account.name, account.type, null);
            final AccountType type = mTypeProvider.getTypeForAccount(accountWithDataSet);

            if (type != null) {
                // Accounts with a dataSet (e.g. Google plus accounts) are not writable.
                result.add(type.wrapAccount(mContext, accountWithDataSet));
            }
        }
        return result;
    }