summaryrefslogtreecommitdiff
path: root/addons/mail/static/src/js/composer.js
diff options
context:
space:
mode:
authorChristophe Simonis <chs@odoo.com>2016-04-12 11:56:44 +0200
committerChristophe Simonis <chs@odoo.com>2016-04-12 11:56:44 +0200
commit21c7ef8bf5aeaf457573276e06a77c0f0cb50f98 (patch)
treef5e32fd9fbff5fe59d76b1a05e6dc8984e46ab38 /addons/mail/static/src/js/composer.js
parent887108b1c4a49d6c6109f749fe8d434b874699af (diff)
parenteb443410ff0bd1bbec33a8d76dc9b279dbf34d70 (diff)
[MERGE] forward port of branch saas-9 up to eb44341
Diffstat (limited to 'addons/mail/static/src/js/composer.js')
-rw-r--r--addons/mail/static/src/js/composer.js7
1 files changed, 1 insertions, 6 deletions
diff --git a/addons/mail/static/src/js/composer.js b/addons/mail/static/src/js/composer.js
index 30c4e3c7a6e..dc90c2891e4 100644
--- a/addons/mail/static/src/js/composer.js
+++ b/addons/mail/static/src/js/composer.js
@@ -230,12 +230,7 @@ var MentionManager = Widget.extend({
},
get_selection_id: function (match, selection) {
- var m = match[0].slice(1);
- _.each(selection, function (s) {
- if(s.name == m){
- return s.id;
- }
- });
+ return _.findWhere(selection, {'name': match[0].slice(1)}).id;
},
reset_selections: function () {