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

Commit 5294207c authored by Wenyi Wang's avatar Wenyi Wang
Browse files

Stop setting default directory in URI

Bug: 28330423

Test: manually verified:
      - duplicates are not seen for the database where the bug was
        seen
      - duplicates are not seen for other databases, in all contacts
        view or in account view
      - all lists in tests app look ok

Change-Id: I0b77080186f4ef22a61a1a2f12686c5903f5a5d5
parent 386a229e
Loading
Loading
Loading
Loading
+0 −3
Original line number Diff line number Diff line
@@ -178,13 +178,10 @@ public class DefaultContactListAdapter extends ContactListAdapter {
            uri = ContactListAdapter.buildSectionIndexerUri(uri);
        }

        // The "All accounts" filter is the same as the entire contents of Directory.DEFAULT
        if (filter != null
                && filter.filterType != ContactListFilter.FILTER_TYPE_CUSTOM
                && filter.filterType != ContactListFilter.FILTER_TYPE_SINGLE_CONTACT) {
            final Uri.Builder builder = uri.buildUpon();
            builder.appendQueryParameter(
                    ContactsContract.DIRECTORY_PARAM_KEY, String.valueOf(Directory.DEFAULT));
            if (filter.filterType == ContactListFilter.FILTER_TYPE_ACCOUNT
                || filter.filterType == ContactListFilter.FILTER_TYPE_GROUP_MEMBERS) {
                filter.addAccountQueryParameterToUrl(builder);