summaryrefslogtreecommitdiff
path: root/addons/mail/static/src/js/services/mail_manager.js
diff options
context:
space:
mode:
authorChristophe Simonis <chs@odoo.com>2019-08-20 12:17:04 +0200
committerChristophe Simonis <chs@odoo.com>2019-08-20 12:17:04 +0200
commitf26de445e5579913e27ea6a630bcee6d40eefc7d (patch)
tree8b8e06be8a9d5fd3c1e5c31634611127446b9948 /addons/mail/static/src/js/services/mail_manager.js
parentbc6accc5688d3c38a35949751779f808e9c2063f (diff)
parent6f55fd65da8c50d36ca97654a920fb075076f125 (diff)
[MERGE] forward port branch saas-12.3 up to 6f55fd65da8
Diffstat (limited to 'addons/mail/static/src/js/services/mail_manager.js')
-rw-r--r--addons/mail/static/src/js/services/mail_manager.js3
1 files changed, 2 insertions, 1 deletions
diff --git a/addons/mail/static/src/js/services/mail_manager.js b/addons/mail/static/src/js/services/mail_manager.js
index 4a20d24af8d..3ed4031abeb 100644
--- a/addons/mail/static/src/js/services/mail_manager.js
+++ b/addons/mail/static/src/js/services/mail_manager.js
@@ -85,7 +85,7 @@ var MailManager = AbstractService.extend({
addMessage: function (data, options) {
options = options || {};
var message = this.getMessage(data.id);
- var prom = Promise.resolve();
+ var prom;
if (!message) {
prom = this._addNewMessage(data, options);
} else {
@@ -95,6 +95,7 @@ var MailManager = AbstractService.extend({
});
}
this._addMessageToThreads(message, options);
+ prom = Promise.resolve(message);
}
return prom;
},