when adding filters, just add them

let the state watcher do the heavy lifting to de-dupe and merge filters
This commit is contained in:
Joe Fleming 2015-05-14 12:01:43 -07:00
parent d029b348e0
commit 8bc5b66664

View file

@ -48,11 +48,7 @@ define(function (require) {
globalState.filters = globalState.filters.concat(filters);
} else if (appState) {
if (!appState.filters) appState.filters = [];
var mergeOptions = { disabled: true, negate: false };
var appFilters = appState.filters.concat(filters);
var merged = mergeAndMutateFilters(globalState.filters, appFilters, mergeOptions);
globalState.filters = merged[0];
appState.filters = merged[1];
appState.filters = appState.filters.concat(filters);
}
return saveState();