Commit 917a5140 authored by Phil Hughes's avatar Phil Hughes

Fixed bug with label filter dropdown not removing the correct label

parent 7124e510
...@@ -250,8 +250,11 @@ ...@@ -250,8 +250,11 @@
} else if (label.title) { } else if (label.title) {
BoardsStore.state.filters['label_name'].push(label.title); BoardsStore.state.filters['label_name'].push(label.title);
} else { } else {
var labelIndex = BoardsStore.state.filters['label_name'].indexOf(label.text()); var filters = BoardsStore.state.filters['label_name'];
BoardsStore.state.filters['label_name'].splice(labelIndex, 1); filters = filters.filter(function (label) {
return label !== $el.text().trim();
});
BoardsStore.state.filters['label_name'] = filters;
} }
BoardsStore.updateFiltersUrl(); BoardsStore.updateFiltersUrl();
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment