From 5fec0d1f19467dd2826e24c43e66cb114911a30b Mon Sep 17 00:00:00 2001 From: Richard Steinmetz Date: Thu, 8 Feb 2024 18:36:11 +0100 Subject: [PATCH] fix(composer): duplicate label in to, cc and bcc selects Signed-off-by: Richard Steinmetz --- src/components/Composer.vue | 10 ++-------- 1 file changed, 2 insertions(+), 8 deletions(-) diff --git a/src/components/Composer.vue b/src/components/Composer.vue index df84863c57..b3e545fbaf 100644 --- a/src/components/Composer.vue +++ b/src/components/Composer.vue @@ -1217,16 +1217,10 @@ export default { this.onNewAddr(addr, this.selectBcc) }, onNewAddr(addr, list) { - if (list.some((recipient) => recipient.email === addr)) { + if (list.some((recipient) => recipient.email === addr.email)) { return } - let res = addr - if (!this.allRecipients.some((recipient) => recipient.email === addr)) { - res = { - ...addr, - email: addr.label, - } - } + let res = { ...addr } this.newRecipients.push(res) list.push(res) this.saveDraftDebounced()