diff options
author | Raimund Schlüßler <raimund.schluessler@mailbox.org> | 2020-01-06 20:41:37 +0100 |
---|---|---|
committer | Raimund Schlüßler <raimund.schluessler@mailbox.org> | 2020-01-06 20:41:37 +0100 |
commit | 6067621b2678717752821efe60b02c7a73638c06 (patch) | |
tree | ef0d404c15ce637b176d9d074259cacb9a5309f0 /src/store | |
parent | fb8df09b18fc5cd8fcb1612fe14492c9a24ed55f (diff) |
Only add sharee if not present already
Signed-off-by: Raimund Schlüßler <raimund.schluessler@mailbox.org>
Diffstat (limited to 'src/store')
-rw-r--r-- | src/store/addressbooks.js | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/src/store/addressbooks.js b/src/store/addressbooks.js index e237c1b6..5871d791 100644 --- a/src/store/addressbooks.js +++ b/src/store/addressbooks.js @@ -199,7 +199,9 @@ const mutations = { isGroup, uri, } - addressbook.shares.push(newSharee) + if (!addressbook.shares.some((share) => share.uri === uri)) { + addressbook.shares.push(newSharee) + } }, /** |