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

Commit 531ec216 authored by Wileen Chiu's avatar Wileen Chiu
Browse files

Remove conference participants from cached list

- when a conference call is disconnected, remove the
participants from the cached list of participants and
their connect time

Change-Id: I37792e6d093a6ee5c66ea7ef86f6755eb1e513d1
Bug: 143468041
parent d1a1231e
Loading
Loading
Loading
Loading
+13 −0
Original line number Diff line number Diff line
@@ -2444,6 +2444,19 @@ public class ImsPhoneCallTracker extends CallTracker implements ImsPullCall {
            //detach the disconnected connections
            conn.getCall().detach(conn);
            removeConnection(conn);

            // remove conference participants from the cached list when call is disconnected
            List<ConferenceParticipant> cpList = imsCall.getConferenceParticipants();
            if (cpList != null) {
                for (ConferenceParticipant cp : cpList) {
                    String number = ConferenceParticipant.getParticipantAddress(cp.getHandle(),
                            getCountryIso()).getSchemeSpecificPart();
                    if (!TextUtils.isEmpty(number)) {
                        String formattedNumber = getFormattedPhoneNumber(number);
                        mPhoneNumAndConnTime.remove(formattedNumber);
                    }
                }
            }
        }

        if (changed) {