Skip to content

Commit

Permalink
Merge pull request #4441 from nextcloud/issue-4405-fix-filter
Browse files Browse the repository at this point in the history
Align filter behavior with web
  • Loading branch information
rapterjet2004 authored Nov 14, 2024
2 parents e1a3a03 + ab4b3d6 commit 3908d0c
Showing 1 changed file with 11 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -1144,8 +1144,17 @@ class ConversationsListActivity :
private fun performFilterAndSearch(filter: String?) {
if (filter!!.length >= SEARCH_MIN_CHARS) {
clearMessageSearchResults()
adapter!!.setFilter(filter)
adapter!!.filterItems()

if (hasFilterEnabled()) {
adapter?.updateDataSet(conversationItems)
adapter!!.setFilter(filter)
adapter!!.filterItems()
adapter?.updateDataSet(filterableConversationItems)
} else {
adapter!!.setFilter(filter)
adapter!!.filterItems()
}

if (isUnifiedSearchAvailable(currentUser!!.capabilities!!.spreedCapability!!)) {
startMessageSearch(filter)
}
Expand Down

0 comments on commit 3908d0c

Please sign in to comment.