mirror of
https://github.com/kiwix/kiwix-android.git
synced 2025-08-03 18:56:44 -04:00
Fixed duplicate searched items are showing
This commit is contained in:
parent
90e7e8d7f7
commit
9cfe35a95e
@ -141,7 +141,7 @@ class SearchFragment : BaseFragment() {
|
||||
if (fetchMoreSearchResults?.isNotEmpty() == true) {
|
||||
// Check if there is no duplicate entry, this is specially added for searched history items.
|
||||
val nonDuplicateResults = fetchMoreSearchResults.filter { newItem ->
|
||||
searchAdapter?.items?.any { it != newItem } == true
|
||||
searchAdapter?.items?.none { it == newItem } ?: true
|
||||
}
|
||||
|
||||
// Append new data (non-duplicate items) to the existing dataset
|
||||
|
Loading…
x
Reference in New Issue
Block a user