diff --git a/app/src/main/java/com/tari/android/wallet/ui/fragment/tx/HomeFragmentViewModel.kt b/app/src/main/java/com/tari/android/wallet/ui/fragment/tx/HomeFragmentViewModel.kt index 32fa4f5de..3c1fb8392 100644 --- a/app/src/main/java/com/tari/android/wallet/ui/fragment/tx/HomeFragmentViewModel.kt +++ b/app/src/main/java/com/tari/android/wallet/ui/fragment/tx/HomeFragmentViewModel.kt @@ -81,7 +81,7 @@ class HomeFragmentViewModel : CommonViewModel() { private val _refreshBalanceInfo = SingleLiveEvent() val refreshBalanceInfo: SingleLiveEvent = _refreshBalanceInfo - val txList = MediatorLiveData>() + val txList = MediatorLiveData>() val emoji = MutableLiveData() @@ -106,7 +106,7 @@ class HomeFragmentViewModel : CommonViewModel() { private fun updateList() { val list = transactionRepository.list.value ?: return - txList.postValue(list.filterIsInstance().sortedByDescending { it.tx.timestamp }.takeLast(TRANSACTION_AMOUNT_HOME_PAGE).toMutableList()) + txList.postValue(list.filterIsInstance().sortedByDescending { it.tx.timestamp }.take(TRANSACTION_AMOUNT_HOME_PAGE)) } fun processItemClick(item: CommonViewHolderItem) {