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

Commit d123f744 authored by Yorke Lee's avatar Yorke Lee Committed by Android Git Automerger
Browse files

am ad6e03a4: am 568a22f1: Fix potential mismatched caller information

* commit 'ad6e03a4087000459bd82b0b49366dcd18117e4b':
  Fix potential mismatched caller information
parents 558b3030 a00ed077
Loading
Loading
Loading
Loading
+9 −1
Original line number Diff line number Diff line
@@ -513,7 +513,15 @@ public class CallCardPresenter extends Presenter<CallCardPresenter.CallCardUi>
    }

    private void onContactInfoComplete(String callId, ContactCacheEntry entry, boolean isPrimary) {
        final boolean entryMatchesExistingCall =
                (isPrimary && mPrimary != null && TextUtils.equals(callId,  mPrimary.getId())) ||
                (!isPrimary && mSecondary != null && TextUtils.equals(callId, mSecondary.getId()));
        if (entryMatchesExistingCall) {
            updateContactEntry(entry, isPrimary);
        } else {
            Log.w(this, "Dropping stale contact lookup info for " + callId);
        }

        if (entry.name != null) {
            Log.d(TAG, "Contact found: " + entry);
        }