diff options
author | Maximilian Hils <git@maximilianhils.com> | 2016-10-31 05:30:32 -0700 |
---|---|---|
committer | Maximilian Hils <git@maximilianhils.com> | 2016-11-08 17:54:27 +0100 |
commit | 85476d9915f23fc45e64b5242e804623f50cd20a (patch) | |
tree | 9fdca1d74c1bcf3f9dafc26cd4d2786c3ae8b81e /mitmproxy/tools/web/master.py | |
parent | 62ca89649237cb0aff63b1fd3d7729b42134bdd1 (diff) | |
download | mitmproxy-85476d9915f23fc45e64b5242e804623f50cd20a.tar.gz mitmproxy-85476d9915f23fc45e64b5242e804623f50cd20a.tar.bz2 mitmproxy-85476d9915f23fc45e64b5242e804623f50cd20a.zip |
clean up mitmweb
Diffstat (limited to 'mitmproxy/tools/web/master.py')
-rw-r--r-- | mitmproxy/tools/web/master.py | 15 |
1 files changed, 7 insertions, 8 deletions
diff --git a/mitmproxy/tools/web/master.py b/mitmproxy/tools/web/master.py index 2f1fd4e3..605cdf18 100644 --- a/mitmproxy/tools/web/master.py +++ b/mitmproxy/tools/web/master.py @@ -29,7 +29,7 @@ class _WebState(): } self.events.append(entry) app.ClientConnection.broadcast( - type="UPDATE_EVENTLOG", + resource="events", cmd="add", data=entry ) @@ -38,9 +38,8 @@ class _WebState(): super().clear() self.events.clear() app.ClientConnection.broadcast( - type="UPDATE_EVENTLOG", - cmd="reset", - data=[] + resource="events", + cmd="reset" ) @@ -113,28 +112,28 @@ class WebMaster(master.Master): def _sig_add(self, view, flow): app.ClientConnection.broadcast( - type="UPDATE_FLOWS", + resource="flows", cmd="add", data=app.convert_flow_to_json_dict(flow) ) def _sig_update(self, view, flow): app.ClientConnection.broadcast( - type="UPDATE_FLOWS", + resource="flows", cmd="update", data=app.convert_flow_to_json_dict(flow) ) def _sig_remove(self, view, flow): app.ClientConnection.broadcast( - type="UPDATE_FLOWS", + resource="flows", cmd="remove", data=dict(id=flow.id) ) def _sig_refresh(self, view): app.ClientConnection.broadcast( - type="UPDATE_FLOWS", + resource="flows", cmd="reset" ) |