summaryrefslogtreecommitdiffstats
path: root/client/lib/multiSelection.js
diff options
context:
space:
mode:
authorXavier Priour <xavier.priour@bubblyware.com>2015-10-23 03:38:38 +0200
committerXavier Priour <xavier.priour@bubblyware.com>2015-10-23 03:38:38 +0200
commit658ef5ebe112edd55eb8cf160e02a46eb2e13afd (patch)
tree91991e142582b1ae71f5369a8ef9c202908ba8c2 /client/lib/multiSelection.js
parent027aacb50e2baf715c89d914e34132458cf11691 (diff)
parentb3696e1e3b366770af8c41861b5cf996cdd2378a (diff)
downloadwekan-658ef5ebe112edd55eb8cf160e02a46eb2e13afd.tar.gz
wekan-658ef5ebe112edd55eb8cf160e02a46eb2e13afd.tar.bz2
wekan-658ef5ebe112edd55eb8cf160e02a46eb2e13afd.zip
Merge branch 'devel' into feature/import-board-members
Diffstat (limited to 'client/lib/multiSelection.js')
-rw-r--r--client/lib/multiSelection.js9
1 files changed, 5 insertions, 4 deletions
diff --git a/client/lib/multiSelection.js b/client/lib/multiSelection.js
index c2bb2bbc..eeb2015d 100644
--- a/client/lib/multiSelection.js
+++ b/client/lib/multiSelection.js
@@ -119,12 +119,13 @@ MultiSelection = {
}
},
- toggle(cardIds, options) {
+ toggle(cardIds, options = {}) {
cardIds = _.isString(cardIds) ? [cardIds] : cardIds;
- options = _.extend({
+ options = {
add: true,
remove: true,
- }, options || {});
+ ...options,
+ };
if (!this.isActive()) {
this.reset();
@@ -133,7 +134,7 @@ MultiSelection = {
const selectedCards = this._selectedCards.get();
- _.each(cardIds, (cardId) => {
+ cardIds.forEach((cardId) => {
const indexOfCard = selectedCards.indexOf(cardId);
if (options.remove && indexOfCard > -1)