Stop clobbering conversation attributes
Unless the background page fetches the latest details of a conversation before updating it, it may clobber or nullify some attributes e.g., the contact's name.
This commit is contained in:
parent
29bf70b76f
commit
ce4ce164af
1 changed files with 35 additions and 33 deletions
|
@ -93,6 +93,7 @@
|
||||||
type : 'private'
|
type : 'private'
|
||||||
}, { merge : true } );
|
}, { merge : true } );
|
||||||
|
|
||||||
|
conversation.fetch().always(function() {
|
||||||
var message = messages.add({
|
var message = messages.add({
|
||||||
source : pushMessage.source,
|
source : pushMessage.source,
|
||||||
sourceDevice : pushMessage.sourceDevice,
|
sourceDevice : pushMessage.sourceDevice,
|
||||||
|
@ -132,6 +133,7 @@
|
||||||
});
|
});
|
||||||
});
|
});
|
||||||
});
|
});
|
||||||
|
});
|
||||||
};
|
};
|
||||||
|
|
||||||
extension.on('message:decrypted', function(options) {
|
extension.on('message:decrypted', function(options) {
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue