From f1cfa57f426e90b10bec80f296e06c58c33ea550 Mon Sep 17 00:00:00 2001 From: Sylvain Berfini Date: Mon, 7 Aug 2023 16:03:15 +0200 Subject: [PATCH] Fixed call logs details duplicated each time they are displayed --- .../main/history/fragments/DetailCallLogFragment.kt | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/app/src/main/java/org/linphone/activities/main/history/fragments/DetailCallLogFragment.kt b/app/src/main/java/org/linphone/activities/main/history/fragments/DetailCallLogFragment.kt index ee2e24d1b..8bb760ec9 100644 --- a/app/src/main/java/org/linphone/activities/main/history/fragments/DetailCallLogFragment.kt +++ b/app/src/main/java/org/linphone/activities/main/history/fragments/DetailCallLogFragment.kt @@ -53,7 +53,9 @@ class DetailCallLogFragment : GenericFragment() { viewModel = callLogGroup.lastCallLogViewModel binding.viewModel = viewModel - viewModel.addRelatedCallLogs(callLogGroup.callLogs) + if (viewModel.relatedCallLogs.value.orEmpty().isEmpty()) { + viewModel.addRelatedCallLogs(callLogGroup.callLogs) + } useMaterialSharedAxisXForwardAnimation = sharedViewModel.isSlidingPaneSlideable.value == false