stream-chat-react icon indicating copy to clipboard operation
stream-chat-react copied to clipboard

bug: `unread` on ChannelPreview not updating after muting & unmuting a channel

Open davidmeredith-hudl opened this issue 1 year ago • 0 comments

Describe the bug The unread prop on the ChannelPreview component is not updating correctly after a channel is muted and then unmuted.

To Reproduce

Steps to reproduce the behavior:

  1. Have a channel with at least one unread message.
  2. Mute the channel using channel.mute(). I believe this is the point where unread gets set to 0.
  3. Unmute the channel using channel.unmute().
  4. Note that unread is still 0, despite the channel being unmuted and having unread messages.

The unread count is correct after following these steps and refreshing the page.

Expected behavior

unread should be updated to the correct number of unread messages in a channel after the unmute action.

Screenshots

If applicable, add screenshots to help explain your problem.

Package version

  • stream-chat-react: 11.8.0
  • stream-chat: 8.16.0

Desktop (please complete the following information):

  • OS: Mac OS 13.6.2
  • Browser: Chrome
  • Version 121.0.6167.184 (Official Build) (arm64)

Additional context

Add any other context about the problem here.

davidmeredith-hudl avatar Mar 01 '24 18:03 davidmeredith-hudl