diff options
| author | Jim Shaver <dcypherd@gmail.com> | 2015-05-31 01:21:44 -0400 |
|---|---|---|
| committer | Jim Shaver <dcypherd@gmail.com> | 2015-05-31 01:21:44 -0400 |
| commit | b51363b3ca43f6572acb673186e6ae78a1f48434 (patch) | |
| tree | a7488b32871c142141a813dc6ff2ede172672c31 /web/src/js/store | |
| parent | 4fe2c069cca07aadf983f54e18dac4de492d5d69 (diff) | |
| parent | 06fba18106a8f759ec6f08453e86772a170c653b (diff) | |
| download | mitmproxy-b51363b3ca43f6572acb673186e6ae78a1f48434.tar.gz mitmproxy-b51363b3ca43f6572acb673186e6ae78a1f48434.tar.bz2 mitmproxy-b51363b3ca43f6572acb673186e6ae78a1f48434.zip | |
Merge remote-tracking branch 'upstream/master' into print-bracket-fix
Conflicts:
examples/har_extractor.py
examples/nonblocking.py
examples/read_dumpfile
libmproxy/web/app.py
Diffstat (limited to 'web/src/js/store')
| -rw-r--r-- | web/src/js/store/view.js | 9 |
1 files changed, 4 insertions, 5 deletions
diff --git a/web/src/js/store/view.js b/web/src/js/store/view.js index 204d22da..d628d46b 100644 --- a/web/src/js/store/view.js +++ b/web/src/js/store/view.js @@ -14,8 +14,6 @@ var default_filt = function (elem) { function StoreView(store, filt, sortfun) { EventEmitter.call(this); - filt = filt || default_filt; - sortfun = sortfun || default_sort; this.store = store; @@ -37,12 +35,13 @@ _.extend(StoreView.prototype, EventEmitter.prototype, { this.store.removeListener("update", this.update); this.store.removeListener("remove", this.remove); this.store.removeListener("recalculate", this.recalculate); + this.removeAllListeners(); }, recalculate: function (filt, sortfun) { - filt = filt || default_filt; - sortfun = sortfun || default_sort; + filt = filt || this.filt || default_filt; + sortfun = sortfun || this.sortfun || default_sort; filt = filt.bind(this); - sortfun = sortfun.bind(this) + sortfun = sortfun.bind(this); this.filt = filt; this.sortfun = sortfun; |
