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

Commit 5f338fa2 authored by Flavio Lerda's avatar Flavio Lerda Committed by Android (Google) Code Review
Browse files

Merge "Do not look up a contact for special numbers."

parents 3f57182c ce75bc9a
Loading
Loading
Loading
Loading
+7 −1
Original line number Diff line number Diff line
@@ -584,7 +584,13 @@ public class CallLogAdapter extends GroupingListAdapter
        ExpirableCache.CachedValue<ContactInfo> cachedInfo =
                mContactInfoCache.getCachedValue(number);
        ContactInfo info = cachedInfo == null ? null : cachedInfo.getValue();
        if (cachedInfo == null) {
        if (!mPhoneNumberHelper.canPlaceCallsTo(number)
                || mPhoneNumberHelper.isVoicemailNumber(number)) {
            // If this is a number that cannot be dialed, there is no point in looking up a contact
            // for it.
            info = ContactInfo.EMPTY;
            formattedNumber = null;
        } else if (cachedInfo == null) {
            mContactInfoCache.put(number, ContactInfo.EMPTY);
            // Use the cached contact info from the call log.
            info = cachedContactInfo;