Fix read sync on duplicate messages
In the case of a double send (same message encrypted and sent twice due to key conflict bug), we would mark the first instance read twice rather than marking both instances read. Fix by searching for matching messages that have not yet been marked read. // FREEBIE
This commit is contained in:
@@ -253,7 +253,7 @@
|
||||
var ids = groups.pluck('id');
|
||||
ids.push(sender);
|
||||
var message = messages.find(function(message) {
|
||||
return (message.get('type') === 'incoming' &&
|
||||
return (message.isIncoming() && message.isUnread() &&
|
||||
_.contains(ids, message.get('conversationId')));
|
||||
});
|
||||
if (message) {
|
||||
|
Reference in New Issue
Block a user