-
Notifications
You must be signed in to change notification settings - Fork 11.2k
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
fix: livechat stuck unread counter on new messages #33229
Conversation
Looks like this PR is ready to merge! 🎉 |
🦋 Changeset detectedLatest commit: aa11286 The changes in this PR will be included in the next version bump. This PR includes changesets to release 1 package
Not sure what this means? Click here to learn what changesets are. Click here if you're a maintainer who wants to add another changeset to this PR |
Codecov ReportAll modified and coverable lines are covered by tests ✅
Additional details and impacted files@@ Coverage Diff @@
## develop #33229 +/- ##
===========================================
+ Coverage 58.58% 59.60% +1.01%
===========================================
Files 2737 2602 -135
Lines 65676 63664 -2012
Branches 14824 14289 -535
===========================================
- Hits 38477 37947 -530
+ Misses 24420 22998 -1422
+ Partials 2779 2719 -60
Flags with carried forward coverage won't be shown. Click here to find out more. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Missing tests ;)
0bc5e79
to
8839035
Compare
chore: refactor processUnread for readability chore: add changeset r a
|
8839035
to
07b6320
Compare
de0d0c1
to
a3bb90f
Compare
This pull request addresses the issue described in CORE-674, where the unread message counter does not update when a livechat visitor, with the widget minimized, receives their first response from an agent. The problem occurs because the
lastReadMessageId
is absent from the livechat client's state, and thegetUnreadMessages
function does not handle this situation correctly.Shoutout to @ggazzo for helping address the changes correctly within the widget code!