Fixed contacts list not updated when side by side with contact editor fragment

This commit is contained in:
Sylvain Berfini 2021-06-21 15:48:27 +02:00
parent 3909d9991d
commit 110295a4c1

View file

@ -80,10 +80,7 @@ class ContactsListViewModel : ViewModel() {
getSelectedContactsList() getSelectedContactsList()
} }
// Prevent blinking items when list hasn't changed contactsList.postValue(list)
if (list.isEmpty() || list.size != contactsList.value.orEmpty().size) {
contactsList.postValue(list)
}
} }
fun deleteContact(contact: Contact?) { fun deleteContact(contact: Contact?) {