bug fix for an "read" status not being sent in case of deleted messages
This commit is contained in:
+2
-1
@@ -2779,7 +2779,6 @@
|
|||||||
// console.log("topic subscriptions updated");
|
// console.log("topic subscriptions updated");
|
||||||
},
|
},
|
||||||
handleNewMessage: function(msg) {
|
handleNewMessage: function(msg) {
|
||||||
clearTimeout(this.readTimer);
|
|
||||||
// Regenerate messages list
|
// Regenerate messages list
|
||||||
var topic = Tinode.getTopic(this.state.topic);
|
var topic = Tinode.getTopic(this.state.topic);
|
||||||
var newState = {messages: []};
|
var newState = {messages: []};
|
||||||
@@ -2791,6 +2790,8 @@
|
|||||||
|
|
||||||
// msg could be null if one or more messages were deleted.
|
// msg could be null if one or more messages were deleted.
|
||||||
if (msg && !msg.deleted) {
|
if (msg && !msg.deleted) {
|
||||||
|
clearTimeout(this.readTimer);
|
||||||
|
|
||||||
// If the message is added to the end of the message list,
|
// If the message is added to the end of the message list,
|
||||||
// scroll to the bottom.
|
// scroll to the bottom.
|
||||||
if (topic.isNewMessage(msg.seq)) {
|
if (topic.isNewMessage(msg.seq)) {
|
||||||
|
|||||||
Reference in New Issue
Block a user