Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Filter conversation list for unread / mentioned conversations #1289

Merged
merged 5 commits into from
Jul 4, 2023

Conversation

Ivansss
Copy link
Member

@Ivansss Ivansss commented Jun 27, 2023

IMG_E0002

Fix #1264

@SystemKeeper
Copy link
Collaborator

Working good in general 👍
Found some issues with filtering and searching.

Case 1:

  • Filter for "Unread"
  • Search for a term where no results are returned
  • Cancel search

Expected: All rooms visible again
Actual: Only unread rooms visible (even though "All" is selected)

Case 2:

  • Filter for unread
  • Search for a term where no results are returned
  • Remove the search term

Expected: Only unread rooms should be visible
Actual:

Both cases seem to have something to do with the 30s timer to update the rooms or atleast the 30s timer influences something here as well.

@Ivansss
Copy link
Member Author

Ivansss commented Jul 4, 2023

Nice catches! ;)

Case 1 fixed in 0b45173
Case 2 fixed in 96befff

Copy link
Collaborator

@SystemKeeper SystemKeeper left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Works :-)

I just noticed that we now have the case that we call self.tableView reloadData twice when refreshRoomList is called and we don't have a search string. Once it's done inside of filterRooms and once in refreshRoomList. Not sure if this will be a problem in the real world or if iOS might even optimize the two calls, but we should keep that in mind and optimize that in the long run.

@SystemKeeper SystemKeeper merged commit fd52768 into master Jul 4, 2023
4 checks passed
@SystemKeeper SystemKeeper deleted the filter-conversation-list branch July 4, 2023 19:31
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Filter conversation list for unread / mentioned conversations only
2 participants