Remove self-listener in conversation model
Since there is the only source/listener on this event, it can be called directly. // FREEBIE
This commit is contained in:
@@ -46,7 +46,6 @@
|
|||||||
|
|
||||||
this.on('change:avatar', this.updateAvatarUrl);
|
this.on('change:avatar', this.updateAvatarUrl);
|
||||||
this.on('destroy', this.revokeAvatarUrl);
|
this.on('destroy', this.revokeAvatarUrl);
|
||||||
this.on('read', this.onReadMessage);
|
|
||||||
this.fetchContacts().then(function() {
|
this.fetchContacts().then(function() {
|
||||||
this.contactCollection.each(function(contact) {
|
this.contactCollection.each(function(contact) {
|
||||||
textsecure.storage.protocol.on('keychange:' + contact.id, function() {
|
textsecure.storage.protocol.on('keychange:' + contact.id, function() {
|
||||||
|
@@ -35,7 +35,7 @@
|
|||||||
|
|
||||||
if (conversation) {
|
if (conversation) {
|
||||||
// notify frontend listeners
|
// notify frontend listeners
|
||||||
conversation.trigger('read', message);
|
conversation.onReadMessage(message);
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
} else {
|
} else {
|
||||||
|
Reference in New Issue
Block a user